1 2014-03-31 Joonghun Park <jh718.park@samsung.com>
3 [EFL][WK2]Implement ewk APIs of web local storage which have deletion functions of the local storage entries
4 https://bugs.webkit.org/show_bug.cgi?id=130577
6 Reviewed by Gyuyoung Kim.
8 * UIProcess/API/efl/ewk_storage_manager.cpp:
9 (ewk_storage_manager_entries_clear):
10 (ewk_storage_manager_entries_for_origin_del):
11 * UIProcess/API/efl/ewk_storage_manager.h:
12 * UIProcess/API/efl/ewk_storage_manager_private.h:
13 (EwkStorageManager::wkStorageManager):
14 * UIProcess/API/efl/tests/test_ewk2_storage_manager.cpp:
15 adding and updating API unittest and fixing memory leak of the existing test case
16 (EWK2StorageManagerTest::getStorageOriginsCallback):
17 (EWK2StorageManagerTest::checkOrigin):
18 (EWK2StorageManagerTest::getOrigin):
21 2014-03-31 Anders Carlsson <andersca@apple.com>
23 Rename policy enums to match the delegate methods
24 https://bugs.webkit.org/show_bug.cgi?id=131002
26 Reviewed by Tim Horton.
28 * UIProcess/API/Cocoa/WKNavigationDelegate.h:
30 * UIProcess/Cocoa/NavigationState.mm:
31 (WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
32 (WebKit::NavigationState::PolicyClient::decidePolicyForResponse):
34 2014-03-31 Anders Carlsson <andersca@apple.com>
37 https://bugs.webkit.org/show_bug.cgi?id=131001
39 Reviewed by Simon Fraser.
41 * UIProcess/API/Cocoa/WKPreferences.h:
42 * UIProcess/API/Cocoa/WKPreferences.mm:
43 (-[WKPreferences isJavaScriptEnabled]):
44 (-[WKPreferences setJavaScriptEnabled:]):
45 (-[WKPreferences javaScriptCanOpenWindowsAutomatically]):
46 (-[WKPreferences setJavaScriptCanOpenWindowsAutomatically:]):
47 (-[WKPreferences suppressesIncrementalRendering]):
48 (-[WKPreferences setSuppressesIncrementalRendering:]):
49 (-[WKPreferences isJavaEnabled]):
50 (-[WKPreferences setJavaEnabled:]):
51 (-[WKPreferences arePlugInsEnabled]):
52 (-[WKPreferences setPlugInsEnabled:]):
54 2014-03-31 Tim Horton <timothy_horton@apple.com>
58 * WebProcess/WebPage/WebPage.cpp:
59 (WebKit::WebPage::updatePreferences):
61 2014-03-31 Simon Fraser <simon.fraser@apple.com>
65 * UIProcess/ios/RemoteLayerTreeHostIOS.mm:
66 (WebKit::RemoteLayerTreeHost::createLayer):
67 * UIProcess/mac/RemoteLayerTreeHost.h:
68 * UIProcess/mac/RemoteLayerTreeHost.mm:
69 (WebKit::RemoteLayerTreeHost::setLayerID):
70 (WebKit::RemoteLayerTreeHost::layerID):
71 (WebKit::RemoteLayerTreeHost::createLayer):
73 2014-03-31 Anders Carlsson <andersca@apple.com>
75 Add a couple of iOS specific preferences
76 https://bugs.webkit.org/show_bug.cgi?id=130999
78 Reviewed by Simon Fraser.
80 * Shared/WebPreferencesStore.h:
81 * UIProcess/API/Cocoa/WKPreferences.h:
82 * UIProcess/API/Cocoa/WKPreferences.mm:
83 (-[WKPreferences allowsInlineMediaPlayback]):
84 (-[WKPreferences setAllowsInlineMediaPlayback:]):
85 (-[WKPreferences mediaPlaybackRequiresUserAction]):
86 (-[WKPreferences setMediaPlaybackRequiresUserAction:]):
87 (-[WKPreferences mediaPlaybackAllowsAirPlay]):
88 (-[WKPreferences setMediaPlaybackAllowsAirPlay:]):
89 * WebProcess/WebPage/WebPage.cpp:
90 (WebKit::WebPage::updatePreferences):
92 2014-03-31 Anders Carlsson <andersca@apple.com>
94 Add a new -[WKPreferences initWithUserDefaultsPrefixKey:] initializer
95 https://bugs.webkit.org/show_bug.cgi?id=130996
97 Reviewed by Simon Fraser.
99 Add a "key prefix" to the WebKit::WebPreferences create function, so we can use a different
100 key prefix ("WebKit") for the modern API and not pollute the user defaults namespace with
101 the old key prefix ("WebKit2.").
103 * UIProcess/API/C/WKPreferences.cpp:
104 (WKPreferencesCreate):
105 (WKPreferencesCreateWithIdentifier):
106 * UIProcess/API/Cocoa/WKPreferences.h:
107 * UIProcess/API/Cocoa/WKPreferences.mm:
108 (-[WKPreferences init]):
109 (-[WKPreferences initWithUserDefaultsPrefixKey:]):
110 (-[WKPreferences userDefaultsPrefixKey]):
111 * UIProcess/WebPageGroup.cpp:
112 (WebKit::WebPageGroup::WebPageGroup):
113 * UIProcess/WebPreferences.cpp:
114 (WebKit::WebPreferences::WebPreferences):
115 * UIProcess/WebPreferences.h:
116 (WebKit::WebPreferences::create):
117 * UIProcess/mac/WebPreferencesMac.mm:
119 (WebKit::setStringValueIfInUserDefaults):
120 (WebKit::setBoolValueIfInUserDefaults):
121 (WebKit::setUInt32ValueIfInUserDefaults):
122 (WebKit::setDoubleValueIfInUserDefaults):
123 (WebKit::WebPreferences::platformInitializeStore):
124 (WebKit::WebPreferences::platformUpdateStringValueForKey):
125 (WebKit::WebPreferences::platformUpdateBoolValueForKey):
126 (WebKit::WebPreferences::platformUpdateUInt32ValueForKey):
127 (WebKit::WebPreferences::platformUpdateDoubleValueForKey):
128 (WebKit::WebPreferences::platformUpdateFloatValueForKey):
130 2014-03-31 Pratik Solanki <psolanki@apple.com>
132 Remove duplicate entries in Derived Sources.
134 Rubber-stamped by Anders Carlsson.
136 * WebKit2.xcodeproj/project.pbxproj:
138 2014-03-31 Tim Horton <timothy_horton@apple.com>
142 * UIProcess/mac/RemoteLayerTreeHost.mm:
143 (WebKit::RemoteLayerTreeHost::updateLayerTree):
145 2014-03-31 Tim Horton <timothy_horton@apple.com>
149 * UIProcess/mac/RemoteLayerTreeHost.mm:
150 (WebKit::RemoteLayerTreeHost::updateLayerTree):
152 2014-03-31 Anders Carlsson <andersca@apple.com>
154 Rename -[WKNavigationAction destinationFrame] to -[WKNavigationAction targetFrame]
155 https://bugs.webkit.org/show_bug.cgi?id=130994
157 Reviewed by Dan Bernstein.
159 * UIProcess/API/Cocoa/WKNavigationAction.h:
160 * UIProcess/API/Cocoa/WKNavigationAction.mm:
161 (-[WKNavigationAction description]):
162 (-[WKNavigationAction targetFrame]):
163 (-[WKNavigationAction setTargetFrame:]):
164 (-[WKNavigationAction destinationFrame]): Deleted.
165 (-[WKNavigationAction setDestinationFrame:]): Deleted.
166 * UIProcess/API/Cocoa/WKNavigationActionInternal.h:
167 * UIProcess/Cocoa/NavigationState.mm:
168 (WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
170 2014-03-31 Tim Horton <timothy_horton@apple.com>
172 [iOS WebKit2] Flush all surfaces after painting into all of them, instead of after painting into each one
173 https://bugs.webkit.org/show_bug.cgi?id=130768
174 <rdar://problem/16421471>
176 Reviewed by Benjamin Poulain.
178 * Shared/mac/RemoteLayerBackingStore.h:
179 Make RemoteLayerBackingStore noncopyable.
180 Add flush(), which synchronously flushes painting operations on the underlying backing store.
181 Add storage for the CGContext that needs to be flushed, and ensure that it is flushed before we paint again.
183 * Shared/mac/RemoteLayerBackingStore.mm:
184 (RemoteLayerBackingStore::display):
186 (RemoteLayerBackingStore::drawInContext):
187 Don't flush the context immediately after painting.
189 (RemoteLayerBackingStore::flush):
190 Flush the current front surface/buffer's context.
191 Clear the new pending-flush members.
193 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
194 (WebKit::flushBackingStoreChangesInTransaction):
195 (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
196 Crawl through all of the valid changed backing stores in the transaction and flush them.
197 Reset changed properties after encoding the commit.
199 * Shared/mac/RemoteLayerTreeTransaction.h:
200 (WebKit::RemoteLayerTreeTransaction::LayerProperties::resetChangedProperties):
201 (WebKit::RemoteLayerTreeTransaction::changedLayers):
202 (WebKit::RemoteLayerTreeTransaction::changedLayerProperties):
203 * Shared/mac/RemoteLayerTreeTransaction.mm:
204 (WebKit::RemoteLayerTreeTransaction::LayerProperties::LayerProperties):
205 (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
206 (WebKit::RemoteLayerTreeTransaction::encode):
207 (WebKit::RemoteLayerTreeTransaction::decode):
208 (WebKit::RemoteLayerTreeTransaction::layerPropertiesChanged):
209 (WebKit::dumpChangedLayers):
210 Instead of storing a copy of the LayerProperties struct for each changed layer
211 while building the transaction in the Web process, store a list of changed layers,
212 and directly encode the commit from those layers' LayerProperties. This provides a few benefits:
213 - We avoid copying LayerProperties for every changed layer, every commit
214 - We can make RemoteLayerBackingStore noncopyable
215 - We can walk the changed layers after building the transaction
216 in order to flush backing store, and actually affect the layers'
217 own RemoteLayerBackingStore instead of a copy.
218 The UI process will still generate a LayerPropertiesMap at decode time.
220 * UIProcess/mac/RemoteLayerTreeHost.mm:
221 (WebKit::RemoteLayerTreeHost::updateLayerTree):
222 Don't copy the LayerProperties struct for the debug overlay. Instead,
223 adjust the properties which the debug overlay whacks directly on the layer,
224 after applying the normal LayerProperties.
226 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
227 (PlatformCALayerRemote::recursiveBuildTransaction):
228 Don't reset changed layer properties in the middle of building a transaction. Instead,
229 RemoteLayerTreeDrawingArea::flushLayers() will reset all the flags on all changed layers
230 after the commit is encoded.
232 * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
233 (WebKit::PlatformCALayerRemote::properties):
235 2014-03-31 Simon Fraser <simon.fraser@apple.com>
237 [UI-side compositing] Proxy animations to the UI process
238 https://bugs.webkit.org/show_bug.cgi?id=130946
240 Reviewed by Tim Horton.
242 Add encoding/decoding of TimingFunctions. Add encoding support
245 Add PlatformCAAnimationRemote and have PlatformCALayerRemote allow
246 animations now. PlatformCALayerRemote's properties are defined in the class,
247 as is the encoding/decoding (much cleaner than having them in the transaction
250 Add support for the "animationDidStart" callback and sending this back to the
251 web process. This involves a HashMap of layerID->WKAnimationDelegate stored
252 on the RemoteLayerTreeHost, and a message send via the DrawingArea. On the
253 other side, RemoteLayerTreeContext stores a HashMap of layerID->PlatformCALayerRemote*
254 for layers which have just started animations, which is used to get the
255 PlatformCALayer* to call animationDidStart() on.
257 This requires that the RemoteLayerTreeHost* be passed down into property application,
258 and that the RemoteLayerTreeHost have a reference to the drawing area.
260 To every CALayer in the UI process we -setValue:forKey: to track the PlatformLayerID,
261 so we can get back to it in order to dispatch "animationDidStart".
263 Replace some "using namespace WebKit" with "namespace WebKit { }".
265 * Platform/IPC/ArgumentCoders.h:
266 * Shared/WebCoreArgumentCoders.cpp:
267 (IPC::ArgumentCoder<LinearTimingFunction>::encode):
268 (IPC::ArgumentCoder<LinearTimingFunction>::decode):
269 (IPC::ArgumentCoder<CubicBezierTimingFunction>::encode):
270 (IPC::ArgumentCoder<CubicBezierTimingFunction>::decode):
271 (IPC::ArgumentCoder<StepsTimingFunction>::encode):
272 (IPC::ArgumentCoder<StepsTimingFunction>::decode):
273 * Shared/WebCoreArgumentCoders.h:
274 * Shared/mac/RemoteLayerBackingStore.mm:
275 * Shared/mac/RemoteLayerTreePropertyApplier.h:
276 * Shared/mac/RemoteLayerTreePropertyApplier.mm:
277 (WebKit::applyPropertiesToLayer):
278 (WebKit::RemoteLayerTreePropertyApplier::applyProperties):
279 * Shared/mac/RemoteLayerTreeTransaction.h:
280 * Shared/mac/RemoteLayerTreeTransaction.mm:
281 (WebKit::RemoteLayerTreeTransaction::LayerProperties::LayerProperties):
282 (WebKit::RemoteLayerTreeTransaction::LayerProperties::encode):
283 (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
284 (WebKit::dumpChangedLayers):
285 * UIProcess/ios/RemoteLayerTreeHostIOS.mm:
286 (WebKit::RemoteLayerTreeHost::layerID):
287 (WebKit::RemoteLayerTreeHost::createLayer):
288 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h:
289 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
290 (WebKit::RemoteLayerTreeDrawingAreaProxy::RemoteLayerTreeDrawingAreaProxy):
291 (WebKit::RemoteLayerTreeDrawingAreaProxy::acceleratedAnimationDidStart):
292 (WebKit::RemoteLayerTreeDrawingAreaProxy::showDebugIndicator):
293 * UIProcess/mac/RemoteLayerTreeHost.h:
294 (WebKit::RemoteLayerTreeHost::animationDelegates):
295 * UIProcess/mac/RemoteLayerTreeHost.mm:
296 (WebKit::RemoteLayerTreeHost::RemoteLayerTreeHost):
297 (WebKit::RemoteLayerTreeHost::updateLayerTree):
298 (WebKit::RemoteLayerTreeHost::layerWillBeRemoved):
299 (WebKit::RemoteLayerTreeHost::animationDidStart):
300 (WebKit::RemoteLayerTreeHost::layerID):
301 (WebKit::RemoteLayerTreeHost::createLayer):
302 * WebKit2.xcodeproj/project.pbxproj:
303 * WebProcess/WebPage/DrawingArea.h:
304 (WebKit::DrawingArea::acceleratedAnimationDidStart):
305 * WebProcess/WebPage/DrawingArea.messages.in:
306 * WebProcess/WebPage/mac/GraphicsLayerCARemote.cpp:
307 (WebKit::GraphicsLayerCARemote::createPlatformCAAnimation):
308 * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
309 * WebProcess/WebPage/mac/PlatformCAAnimationRemote.h: Added.
310 * WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm: Added.
311 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
312 (WebKit::PlatformCALayerRemote::recursiveBuildTransaction):
313 (WebKit::PlatformCALayerRemote::animationStarted):
314 (WebKit::PlatformCALayerRemote::addAnimationForKey):
315 (WebKit::PlatformCALayerRemote::removeAnimationForKey):
316 (WebKit::PlatformCALayerRemote::animationForKey):
317 (PlatformCALayerRemote::recursiveBuildTransaction): Deleted.
318 (PlatformCALayerRemote::addAnimationForKey): Deleted.
319 (PlatformCALayerRemote::removeAnimationForKey): Deleted.
320 (PlatformCALayerRemote::animationForKey): Deleted.
321 * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
322 * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp:
323 * WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
324 * WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
325 (WebKit::RemoteLayerTreeContext::layerWillBeDestroyed):
326 (WebKit::RemoteLayerTreeContext::willStartAnimationOnLayer):
327 (WebKit::RemoteLayerTreeContext::animationDidStart):
328 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
329 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
330 (WebKit::RemoteLayerTreeDrawingArea::acceleratedAnimationDidStart):
331 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
332 (WebKit::TiledCoreAnimationDrawingArea::commitTransientZoom):
334 2014-03-31 Tim Horton <timothy_horton@apple.com>
336 Double-buffer RemoteLayerBackingStore
337 https://bugs.webkit.org/show_bug.cgi?id=130990
339 Reviewed by Simon Fraser.
341 We'll keep a front and back buffer for each surface; the front is generally currently
342 being displayed in the UI process, and the back is the one we'll paint into.
344 Swap the two surfaces each time we paint; since we synchronize with the UI process,
345 the old front surface will generally be out-of-use by the render server by the time
346 we paint again. However, since render server commits are asynchronous and we have
347 no way to syncronize with them yet, we have to check if the (swapped to front) back buffer is in use,
348 and create a new front buffer if it is.
350 Triple-buffering would solve this problem, as would synchronization with the render server,
351 as would a pool of surfaces - we will revisit these solutions in future patches.
353 * Shared/mac/RemoteLayerBackingStore.h:
354 * Shared/mac/RemoteLayerBackingStore.mm:
355 (RemoteLayerBackingStore::ensureBackingStore):
356 (RemoteLayerBackingStore::clearBackingStore):
357 Factor clearBackingStore() out of ensureBackingStore() and display().
359 (RemoteLayerBackingStore::display):
360 Swap buffers. Since m_backSurface will hold on to the back surface's CGContext,
361 we don't need to worry about tearing down the image first anymore.
362 Don't worry about creating a back image (nor copying it into the front image)
363 if we're going to paint the whole layer.
365 (RemoteLayerBackingStore::drawInContext):
368 (RemoteLayerBackingStore::applyBackingStoreToLayer):
371 (RemoteLayerBackingStore::createImageForFrontBuffer): Deleted.
373 2014-03-31 Tim Horton <timothy_horton@apple.com>
375 Synchronize Web process remote layer tree commits with CoreAnimation commits in the UI process
376 https://bugs.webkit.org/show_bug.cgi?id=130984
378 Reviewed by Simon Fraser.
380 There's no reason for the Web process to paint faster than the UI process
381 can apply to and commit the CoreAnimation layer tree.
383 Also, once we get proper double-buffering and purgeable back buffers, we
384 will need the ability to make some assumptions about in-use surfaces.
386 Unfortunately, we can't actually tell when the render server commits,
387 as this is an asynchronous operation in a process we don't control, so
388 for now, this is only an approximation.
390 This also means that the assumptions we would like to make won't be
391 strong guarantees yet.
393 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h:
394 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
395 (WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):
396 When we commit, install a run loop observer to fire immediately after CoreAnimation commits.
398 (WebKit::RemoteLayerTreeDrawingAreaProxy::showDebugIndicator):
399 Fix a typo ('cmponents').
401 (WebKit::coreAnimationDidCommitLayersCallback):
402 (WebKit::RemoteLayerTreeDrawingAreaProxy::scheduleCoreAnimationLayerCommitObserver):
403 (WebKit::RemoteLayerTreeDrawingAreaProxy::coreAnimationDidCommitLayers):
404 When CA commits, send a message to the Web process letting it know that we
405 swapped to the new backing store.
407 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
408 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
409 (WebKit::RemoteLayerTreeDrawingArea::RemoteLayerTreeDrawingArea):
410 (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
411 (WebKit::RemoteLayerTreeDrawingArea::didUpdate):
412 Defer remote layer tree commits until we get didUpdate() from the UI process.
414 2014-03-31 Dean Jackson <dino@apple.com>
416 Remove WEB_ANIMATIONS
417 https://bugs.webkit.org/show_bug.cgi?id=130989
419 Reviewed by Simon Fraser.
421 Remove this feature flag until we plan to implement.
423 * Configurations/FeatureDefines.xcconfig:
425 2014-03-31 Simon Fraser <simon.fraser@apple.com>
427 [iOS WK2] Hook up scroll events for accelerated overflow:scroll
428 https://bugs.webkit.org/show_bug.cgi?id=130976
430 Reviewed by Tim Horton.
432 When an accelerated overflow:scroll is scrolled in the UI process,
433 tell the WebProcess that the scroll happened to update RenderLayer
434 state and fire events.
436 Add a WKOverflowScrollViewDelegate which is set as the delegate of
437 UIScrollViews, owned by ScrollingTreeOverflowScrollingNodeIOS, and propagates
438 -scrollViewDidScroll: messages to ScrollingTree::scrollPositionChangedViaDelegatedScrolling(),
439 which updates child layers and then, via RemoteScrollingTree::scrollingTreeNodeDidScroll,
440 tells the RemoteScrollingCoordinator which sends a message to the WebProcess.
442 * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
443 (WebKit::RemoteScrollingCoordinatorProxy::scrollingTreeNodeDidScroll): Name change
444 to try to reduce confusion.
445 (WebKit::RemoteScrollingCoordinatorProxy::scrollPositionChanged): Deleted.
446 * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h:
447 * UIProcess/Scrolling/RemoteScrollingTree.cpp:
448 (WebKit::RemoteScrollingTree::scrollingTreeNodeDidScroll):
449 * UIProcess/Scrolling/RemoteScrollingTree.h:
450 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h:
451 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
452 (-[WKOverflowScrollViewDelegate initWithScrollingTreeNode:WebKit::]):
453 (-[WKOverflowScrollViewDelegate scrollViewDidScroll:]):
454 (-[WKOverflowScrollViewDelegate scrollViewWillBeginDragging:]):
455 (-[WKOverflowScrollViewDelegate scrollViewDidEndDragging:willDecelerate:]):
456 (-[WKOverflowScrollViewDelegate scrollViewDidEndScrollingAnimation:]):
457 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::~ScrollingTreeOverflowScrollingNodeIOS):
458 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::updateBeforeChildren):
459 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::updateAfterChildren):
460 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::scrollViewDidScroll):
461 * WebProcess/Scrolling/RemoteScrollingCoordinator.mm:
462 (WebKit::RemoteScrollingCoordinator::scrollPositionChangedForNode): No need for
465 2014-03-29 Simon Fraser <simon.fraser@apple.com>
467 Fix scrolling on OS X with UI-side compositing
468 https://bugs.webkit.org/show_bug.cgi?id=130930
470 Reviewed by Tim Horton.
472 On iOS, we rely on visible rect updates to propagate scroll offset
473 changes to the WebProcess. RemoteScrollingCoordinatorProxy was thus hardcoded
474 to bail from scrollPositionChanged() when the scrolled node was the root node,
475 but this broke OS X. Fix by adding a behavior flag to RemoteScrollingCoordinatorProxy.
477 * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
478 (WebKit::RemoteScrollingCoordinatorProxy::RemoteScrollingCoordinatorProxy):
479 (WebKit::RemoteScrollingCoordinatorProxy::scrollPositionChanged):
480 * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h:
481 (WebKit::RemoteScrollingCoordinatorProxy::setPropagatesMainFrameScrolls):
482 (WebKit::RemoteScrollingCoordinatorProxy::propagatesMainFrameScrolls):
483 * UIProcess/WebPageProxy.cpp:
484 (WebKit::WebPageProxy::initializeWebPage):
486 2014-03-31 Tim Horton <timothy_horton@apple.com>
488 [iOS WebKit2] Disable tile cohort retention for now
489 https://bugs.webkit.org/show_bug.cgi?id=130926
490 <rdar://problem/16465413>
492 Reviewed by Simon Fraser.
494 * Shared/WebPreferencesStore.h:
495 * WebProcess/WebPage/WebPage.cpp:
496 (WebKit::WebPage::updatePreferences):
497 Add a preference for temporary tile cohort retention (essentially, provide a setting
498 that means that we will never retain tiles at all once they leave the tile coverage rect).
499 Defaults to true to maintain existing behavior, except for iOS WebKit2, where
500 it defaults to false because we don't have the requisite support for purgeable tiles yet.
502 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
503 (WebKit::TiledCoreAnimationDrawingArea::updatePreferences):
504 (WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):
506 2014-03-31 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
508 Buildfix after r166497.
510 Reviewed by Csaba Osztrogonác.
512 * UIProcess/API/efl/ewk_context.h: Missing EAPI added.
514 2014-03-31 Martin Robinson <mrobinson@igalia.com>
516 [GTK] Use PROJECT_VERSION_* instead of WEBKIT_*_VERSION
517 https://bugs.webkit.org/show_bug.cgi?id=130936
519 Reviewed by Carlos Garcia Campos.
521 * UIProcess/API/gtk/WebKitVersion.h.in: Use PROJECT_VERSION_* macros instead of the Autotools ones.
523 2014-03-31 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
525 [EFL][WK2] Add ewk APIs to control TLS error policy on WebContext.
526 https://bugs.webkit.org/show_bug.cgi?id=129740
528 Reviewed by Gyuyoung Kim.
531 Added the new SSL test.
533 * UIProcess/API/efl/ewk_context.cpp:
534 (EwkContext::ignoreTLSErrors):
535 (EwkContext::setIgnoreTLSErrors):
536 (ewk_context_ignore_tls_errors_get):
537 (ewk_context_ignore_tls_errors_set):
538 * UIProcess/API/efl/ewk_context.h:
539 * UIProcess/API/efl/ewk_context_private.h:
540 Added the API functions.
542 * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestServer.cpp:
543 (EWK2UnitTestServer::EWK2UnitTestServer):
544 * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestServer.h:
545 Extended the unit test server to handle TLS.
547 * UIProcess/API/efl/tests/test_ewk2_ssl.cpp:
548 Added tests to check the TLS policy API.
550 2014-03-31 Carlos Garcia Campos <cgarcia@igalia.com>
552 Unreviewed. Fix GTK2 plugin process binary name after r166492.
554 * PlatformGTK.cmake: Fix typo.
556 2014-03-31 Dániel Bátyai <dbatyai.u-szeged@partner.samsung.com>
558 Remove hostThisRegister() and hostThisValue()
559 https://bugs.webkit.org/show_bug.cgi?id=130895
561 Reviewed by Geoffrey Garen.
563 Removed hostThisRegister() and hostThisValue() and instead use thisArgumentOffset() and thisValue() respectively.
565 * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
566 (WebKit::callMethod):
568 2014-03-31 Carlos Garcia Campos <cgarcia@igalia.com>
570 [GTK] Add support for GTK3 plugins
571 https://bugs.webkit.org/show_bug.cgi?id=130599
573 Reviewed by Martin Robinson.
575 We currently have a gtk2 based plugin process mainly for flash
576 and a few other plugins that use GTK2, but many other plugins
577 don't even use gtk at all. This patch builds a lighter plugin
578 process based on GTK3, used by default for all the plugins expect
579 the ones requiring GTK2. And of course the default plugin process
580 supports GTK3 plugins.
582 * CMakeLists.txt: Add common rules to build the default plugin process.
583 * PlatformEfl.cmake: Remove common cmake code that is now in CMakeLists.txt.
584 * PlatformGTK.cmake: Rename WebKitPluginProcess to
585 WebKitPluginProcess2 and add the platform specific rules to build
586 the default plugin process.
587 * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
588 (WebKit::NetscapePluginModule::getPluginInfoForLoadedPlugin):
589 Check if the loaded plugin module uses GTK2.
590 (WebKit::NetscapePluginModule::getPluginInfo): Set requiresGtk2 accordingly.
591 (WebKit::NetscapePluginModule::scanPlugin): Write "requires-gtk2"
592 line to stdout if the plugin requires GTK2.
593 * Shared/Plugins/PluginModuleInfo.h: Add requiresGtk2 boolean member.
594 * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
595 (WebKit::ProcessLauncher::launchProcess): Use the
596 WebKitPluginProcess2 executable when the plugin requires GTK2.
597 * UIProcess/Plugins/PluginProcessProxy.h: Add requiresGtk2 boolean
598 member to RawPluginMetaData struct.
599 * UIProcess/Plugins/gtk/PluginInfoCache.cpp: Bump the cache schema version.
600 (WebKit::PluginInfoCache::getPluginInfo): Read also requires-gtk2
602 (WebKit::PluginInfoCache::updatePluginInfo): Save also
603 requires-gtk2 key in the cache.
604 * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
605 (WebKit::PluginProcessProxy::platformGetLaunchOptions): Add an
606 extra initialization data parameter if the plugin requires GTK2.
607 (WebKit::PluginProcessProxy::scanPlugin): Check if "requires-gtk2"
608 was written to stdout.
610 2014-03-30 Andy Estes <aestes@apple.com>
612 [Cocoa] Add an originatingWebView property to _WKDownload
613 https://bugs.webkit.org/show_bug.cgi?id=130945
615 Reviewed by Anders Carlsson.
617 * UIProcess/API/Cocoa/WKWebView.mm:
618 (-[WKWebView initWithFrame:configuration:]): Passed self to WKView's initializer.
619 * UIProcess/API/Cocoa/_WKDownload.h: Declared originatingWebView as a weak, readonly property.
620 * UIProcess/API/Cocoa/_WKDownload.mm:
621 (-[_WKDownload originatingWebView]):
622 (-[_WKDownload setOriginatingWebView:]):
623 * UIProcess/API/Cocoa/_WKDownloadInternal.h: Re-declared originatingWebView as readwrite so that
624 PageClientImpl can call setOriginatingWebView:. Removed some dead code.
625 * UIProcess/API/mac/WKView.mm:
626 (-[WKView initWithFrame:context:configuration:webView:]): Updated to accept a webView parameter.
627 (-[WKView initWithFrame:contextRef:pageGroupRef:relatedToPage:]): Passed nil for the webView parameter.
628 * UIProcess/API/mac/WKViewInternal.h:
629 * UIProcess/Cocoa/DownloadClient.mm:
630 (WebKit::DownloadClient::decideDestinationWithSuggestedFilename): Ensured allowOverwrite is initialized.
631 * UIProcess/PageClient.h: Included handleDownloadRequest() on all platforms.
632 * UIProcess/WebPageProxy.cpp:
633 (WebKit::WebPageProxy::receivedPolicyDecision): Ditto.
634 (WebKit::WebPageProxy::handleDownloadRequest): Ditto.
635 * UIProcess/WebPageProxy.h: Ditto.
636 * UIProcess/ios/PageClientImplIOS.h:
637 * UIProcess/ios/PageClientImplIOS.mm:
638 (WebKit::PageClientImpl::handleDownloadRequest): Called -[_WKDownload setOriginatingWebView:].
639 * UIProcess/mac/PageClientImpl.h: Added a m_webView member variable.
640 * UIProcess/mac/PageClientImpl.mm:
641 (WebKit::PageClientImpl::PageClientImpl): Asserted that m_webView is nil if WK API isn't enabled.
642 (WebKit::PageClientImpl::handleDownloadRequest): Called -[_WKDownload setOriginatingWebView:].
644 2014-03-29 Commit Queue <commit-queue@webkit.org>
646 Unreviewed, rolling out r166434.
647 https://bugs.webkit.org/show_bug.cgi?id=130938
649 Caused crashes and other failures on cache tests (Requested by
654 "Web Replay: add page-level setting to bypass the MemoryCache"
655 https://bugs.webkit.org/show_bug.cgi?id=130728
656 http://trac.webkit.org/changeset/166434
658 2014-03-28 Anders Carlsson <andersca@apple.com>
660 Uncaught NSExceptions should crash the web process
661 https://bugs.webkit.org/show_bug.cgi?id=130923
662 <rdar://problem/16463751>
664 Reviewed by Dan Bernstein.
666 * WebProcess/cocoa/WebProcessCocoa.mm:
667 (WebKit::WebProcess::platformInitializeWebProcess):
669 2014-03-28 Csaba Osztrogonác <ossy@webkit.org>
671 Unreviewed buildfix after r166441 and r166443.
673 Missing PLATFORM(COCOA) guards added.
675 * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
676 (WebKit::NPRuntimeObjectMap::evaluate):
677 * WebProcess/Plugins/PluginProxy.cpp:
678 * WebProcess/Plugins/PluginProxy.h:
680 2014-03-28 Stephanie Lewis <slewis@apple.com>
682 Don't prevent AppSleep from sync messages.
683 https://bugs.webkit.org/show_bug.cgi?id=130747.
685 Reviewed by Anders Carlsson.
687 We think sync messages only need to happen full throttle when the plugin is visible,
688 the user is interacting with the plugin, or audio is playing. Since we already
689 take assertions for all these cases the assertion in sync messages doesn’t provide
690 any value. Since it can keep the PluginProcess awake in other instances remove it.
692 * PluginProcess/WebProcessConnection.cpp:
693 (WebKit::WebProcessConnection::didReceiveSyncMessage):
695 2014-03-28 Stephanie Lewis <slewis@apple.com>
697 Stop waking up the web process in the background because of plugin activity.
698 Part of <rdar://problem/16061257> PluginProcess should AppNap when no plugins on active tab.
700 Reviewed by Anders Carlsson.
702 Plugin activity in the background can constantly wake up web processes. This is only
703 necessary when audio is playing to support web apps like Pandora and youtube playing
704 in the background. Use a new api in CoreAudio to see if there is audio playing in
707 * PluginProcess/PluginProcess.cpp:
708 (WebKit::PluginProcess::PluginProcess): Add a AudioHardwareListener
709 (WebKit::PluginProcess::createWebProcessConnection): tell web process current state
710 (WebKit::PluginProcess::audioHardwareDidBecomeActive): respond to audio hardware notifications
711 (WebKit::PluginProcess::audioHardwareDidBecomeInactive):
712 * PluginProcess/PluginProcess.h:
713 * PluginProcess/WebProcessConnection.cpp: tell WebProcess when audio state in PluginProcess
715 (WebKit::WebProcessConnection::audioHardwareDidBecomeActive):
716 (WebKit::WebProcessConnection::audioHardwareDidBecomeInactive):
717 * PluginProcess/WebProcessConnection.h:
718 * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
719 Only invoke pageThrottler activity when playing audio
720 (WebKit::NPRuntimeObjectMap::evaluate):
721 * WebProcess/Plugins/Plugin.h: add function to get audio state
722 (WebKit::Plugin::audioIsPlayingInPluginProcess):
723 * WebProcess/Plugins/PluginProcessConnection.cpp: store audio state
724 (WebKit::PluginProcessConnection::PluginProcessConnection):
725 (WebKit::PluginProcessConnection::didReceiveMessage):
726 (WebKit::PluginProcessConnection::audioHardwareDidBecomeActive):
727 (WebKit::PluginProcessConnection::audioHardwareDidBecomeInactive):
728 * WebProcess/Plugins/PluginProcessConnection.h:
729 (WebKit::PluginProcessConnection::audioIsPlaying):
730 * WebProcess/Plugins/PluginProcessConnection.messages.in:
731 * WebProcess/Plugins/PluginProxy.cpp:
732 (WebKit::PluginProxy::audioIsPlayingInPluginProcess):
733 * WebProcess/Plugins/PluginProxy.h:
734 * WebProcess/Plugins/PluginView.cpp:
735 (WebKit::PluginView::audioIsPlayingInPluginProcess):
736 * WebProcess/Plugins/PluginView.h:
738 2014-03-28 Stephanie Lewis <slewis@apple.com>
740 Have the plugin process track visibility of it’s plugin and sleep when none
742 Part of <rdar://problem/16061257> PluginProcess should AppNap when no plugins on active tab.
743 https://bugs.webkit.org/show_bug.cgi?id=130694
745 Reviewed by Anders Carlsson.
747 Currently AppSleep is enabled on the PluginProcess based on web page visibility.
748 Add visibility tracking to plugins and move the decision to AppSleep into the the
751 * PluginProcess/PluginProcess.cpp:
752 (WebKit::PluginProcess::PluginProcess): Add a new activity for visible plugins
753 (WebKit::PluginProcess::pluginsForWebProcessDidBecomeVisible): take an activity
754 assertion if any web processes have a visible plugin.
755 (WebKit::PluginProcess::pluginsForWebProcessDidBecomeHidden):
756 * PluginProcess/PluginProcess.h:
757 * PluginProcess/WebProcessConnection.cpp:
758 (WebKit::WebProcessConnection::removePluginControllerProxy): remove plugin from
759 visible plugins when destroying it
760 (WebKit::WebProcessConnection::pluginDidBecomeVisible):
761 (WebKit::WebProcessConnection::pluginDidBecomeHidden): track which plugins are
762 visible for each web process
763 * PluginProcess/WebProcessConnection.h:
764 * PluginProcess/mac/PluginControllerProxyMac.mm:
765 (WebKit::PluginControllerProxy::windowVisibilityChanged): notify WebProcessConnection
766 when visibility changed.
767 * UIProcess/WebContext.h:
768 * UIProcess/mac/WebContextMac.mm: instead of tracking plugin app sleep state on the web pref.
769 and visibility state, just use the web pref.
770 (WebKit::WebContext::updateProcessSuppressionState):
771 (WebKit::WebContext::processSuppressionPreferenceIsEnabledForAllContexts):
773 2014-03-28 Brian Burg <bburg@apple.com>
775 Web Replay: add page-level setting to bypass the MemoryCache
776 https://bugs.webkit.org/show_bug.cgi?id=130728
778 Reviewed by Timothy Hatcher.
780 * UIProcess/APISession.cpp:
781 (API::generateID): update the base ID for generating unique sessions.
783 2014-03-28 Cody Krieger <cjk@apple.com>
785 Add willSubmitForm callback support to WKWebProcessPlugInFormDelegatePrivate.
787 https://bugs.webkit.org/show_bug.cgi?id=130875
789 Reviewed by Anders Carlsson.
791 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h:
792 Add -_webProcessPlugInBrowserContextController:willSubmitForm:toFrame:fromFrame:withValues:
793 to the WKWebProcessPlugInFormDelegatePrivate protocol.
795 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
796 Wire up the willSubmitForm() callback to the new
797 WKWebProcessPlugInFormDelegatePrivate method.
799 2014-03-28 Alexey Proskuryakov <ap@apple.com>
801 [Mac] Enable async text input implementation
802 https://bugs.webkit.org/show_bug.cgi?id=130856
804 Reviewed by Sam Weinig.
806 * UIProcess/API/mac/WKView.mm: (-[WKView _interpretKeyEvent:completionHandler:]):
807 Temporarily work around <rdar://16393434>.
809 2014-03-28 Alexey Proskuryakov <ap@apple.com>
811 Move sync CancelComposition message under an ifdef
812 https://bugs.webkit.org/show_bug.cgi?id=130908
814 Reviewed by Enrica Casucci.
816 * UIProcess/WebPageProxy.h:
817 * UIProcess/ios/WebPageProxyIOS.mm:
818 (WebKit::WebPageProxy::cancelComposition): Deleted.
819 * UIProcess/mac/WebPageProxyMac.mm:
820 * WebProcess/WebPage/WebPage.h:
821 * WebProcess/WebPage/WebPage.messages.in:
822 * WebProcess/WebPage/mac/WebPageMac.mm:
824 2014-03-28 Alexey Proskuryakov <ap@apple.com>
826 [iOS] Don't cancel composition on selection change
827 https://bugs.webkit.org/show_bug.cgi?id=130909
829 Reviewed by Enrica Casucci.
831 Fixing a recent regression from bug 130727.
833 * WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::didChangeSelection):
835 2014-03-28 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
837 [WK2] Removed unused method logChannelByName.
838 https://bugs.webkit.org/show_bug.cgi?id=130897
840 Reviewed by Anders Carlsson.
842 * Platform/Logging.cpp:
843 (WebKit::logChannelByName): Deleted.
844 * Platform/Logging.h:
846 2014-03-28 Alexey Proskuryakov <ap@apple.com>
848 Eliminate a sync cancelComposition call in WebPageProxy::editorStateChanged
849 https://bugs.webkit.org/show_bug.cgi?id=130727
851 Reviewed by Enrica Casucci.
853 Added a separate CompositionWasCanceled IPC call, with which WebProcess can tell
854 UIProcess that it should notify an input method of canceled composition. There are
855 a lot of incorrect edge cases where we don't call it correctly, but this was true
856 in the old implementation too (for different edge cases).
858 This change only affects iOS and async NSTextInputClient code path on Mac. I don't
859 want to change sync NSTextInputClient code path unless absolutely necessary.
861 * UIProcess/WebPageProxy.cpp:
862 (WebKit::WebPageProxy::WebPageProxy):
863 (WebKit::WebPageProxy::editorStateChanged):
864 (WebKit::WebPageProxy::compositionWasCanceled):
865 (WebKit::WebPageProxy::resetStateAfterProcessExited):
866 * UIProcess/WebPageProxy.h:
867 * UIProcess/WebPageProxy.messages.in:
868 * UIProcess/mac/WebPageProxyMac.mm:
869 (WebKit::WebPageProxy::insertText):
870 (WebKit::WebPageProxy::executeKeypressCommands):
871 * WebProcess/WebPage/WebPage.cpp:
872 (WebKit::WebPage::didChangeSelection):
874 2014-03-28 Mario Sanchez Prada <mario.prada@samsung.com>
876 [GTK] Running minibrowser with url crashes in debug build
877 https://bugs.webkit.org/show_bug.cgi?id=130492
879 Reviewed by Martin Robinson.
881 Use the ResourceRequest(const URL& url) constructor, instead of the
882 one taking a String, to call WebPageProxy::loadRequest(), so we
883 ensure that the passed URI is correctly constructed.
885 * UIProcess/API/gtk/WebKitWebView.cpp:
886 (webkit_web_view_load_uri): Create an URL out of a SoupURI and
887 use that to create a ResourceRequest to pass to loadRequest().
889 2014-03-27 Pratik Solanki <psolanki@apple.com>
891 [iOS WebKit2] Tweak cache sizes for iOS
892 https://bugs.webkit.org/show_bug.cgi?id=130871
894 Reviewed by Sam Weinig.
896 Bring over the tweaks we had made to memory cache size for WebKit1 on iOS to WebKit2. These
897 were made per findings in <rdar://8611638>.
899 * Shared/CacheModel.cpp:
900 (WebKit::calculateCacheSizes):
902 2014-03-27 Jinwoo Song <jinwoo7.song@samsung.com>
904 [WK2][EFL] Fix wrong parameter name in ewk_view_user_agent_set()
905 https://bugs.webkit.org/show_bug.cgi?id=130888
907 Reviewed by Gyuyoung Kim.
909 * UIProcess/API/efl/ewk_view.h:
911 2014-03-27 Alexey Proskuryakov <ap@apple.com>
913 Confirm composition in resignFirstResponder, don't cancel it
914 https://bugs.webkit.org/show_bug.cgi?id=130852
916 Reviewed by Darin Adler.
918 * UIProcess/API/mac/WKView.mm: (-[WKView resignFirstResponder]):
920 2014-03-27 Pratik Solanki <psolanki@apple.com>
922 [iOS WebKit2] Don't pass disk cache directory path on iOS
923 https://bugs.webkit.org/show_bug.cgi?id=130862
925 Reviewed by Sam Weinig.
927 The diskPath passed to NSURLCache initializer is treated differently on Mac and iOS. Just
928 pass nil for now until we sort out the API.
930 * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
931 (WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
932 * WebProcess/cocoa/WebProcessCocoa.mm:
933 (WebKit::WebProcess::platformInitializeWebProcess):
935 2014-03-27 Pratik Solanki <psolanki@apple.com>
937 [iOS WebKit2] Share network process code between iOS and Mac
938 https://bugs.webkit.org/show_bug.cgi?id=130861
940 Reviewed by Sam Weinig.
942 Implement network process functions for iOS by moving common code from NetworkProcessMac.mm
943 to a new shared file NetworkProcessCocoa.mm and sharing between iOS and Mac.
945 * NetworkProcess/NetworkProcess.h:
946 * NetworkProcess/cocoa/NetworkProcessCocoa.mm: Added.
947 (WebKit::NetworkProcess::platformLowMemoryHandler):
948 (WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
949 Common initialization code for iOS and Mac.
950 (WebKit::memorySize):
951 (WebKit::volumeFreeSize):
952 (WebKit::NetworkProcess::platformSetCacheModel):
953 * NetworkProcess/ios/NetworkProcessIOS.mm:
954 (WebKit::NetworkProcess::initializeProcess):
955 Remove unnecessary #if PLATFORM(IOS).
956 (WebKit::NetworkProcess::platformInitializeNetworkProcess):
957 * NetworkProcess/mac/NetworkProcessMac.mm:
958 (WebKit::NetworkProcess::platformInitializeNetworkProcess):
959 * WebKit2.xcodeproj/project.pbxproj:
961 2014-03-27 Enrica Casucci <enrica@apple.com>
963 Add support for AirPlay picker in WK2 for iOS.
964 https://bugs.webkit.org/show_bug.cgi?id=130855
965 <rdar://problem/15349859>
967 Reviewed by Joseph Pecoraro and Benjamin Poulain.
969 Adds support to display the airplay picker for iPhone and iPad
971 The picker on iPad is displayed next to the airplay button.
973 * UIProcess/PageClient.h:
974 * UIProcess/WebPageProxy.h:
975 * UIProcess/WebPageProxy.messages.in:
976 * UIProcess/ios/PageClientImplIOS.h:
977 * UIProcess/ios/PageClientImplIOS.mm:
978 (WebKit::PageClientImpl::showAirPlayRoutePicker):
979 * UIProcess/ios/WKContentViewInteraction.h:
980 * UIProcess/ios/WKContentViewInteraction.mm:
981 (-[WKContentView _showAirPlayRoutePicker:fromRect:]):
982 * UIProcess/ios/WebPageProxyIOS.mm:
983 (WebKit::WebPageProxy::showAirPlayRoutePicker):
984 * UIProcess/ios/forms/WKAirPlayRoutePicker.h: Added.
985 * UIProcess/ios/forms/WKAirPlayRoutePicker.mm: Added.
986 (-[WKAirPlayRoutePicker initWithView:]):
987 (-[WKAirPlayRoutePicker dealloc]):
988 (-[WKAirPlayRoutePicker popoverControllerDidDismissPopover:]):
989 (-[WKAirPlayRoutePicker _presentAirPlayPopoverAnimated:fromRect:]):
990 (-[WKAirPlayRoutePicker _windowWillRotate:]):
991 (-[WKAirPlayRoutePicker _windowDidRotate:]):
992 (-[WKAirPlayRoutePicker _dismissAirPlayRoutePickerIPad]):
993 (-[WKAirPlayRoutePicker showAirPlayPickerIPad:fromRect:]):
994 (-[WKAirPlayRoutePicker showAirPlayPickerIPhone:]):
995 (-[WKAirPlayRoutePicker show:fromRect:]):
996 * WebKit2.xcodeproj/project.pbxproj:
997 * WebProcess/WebCoreSupport/WebChromeClient.h:
998 * WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm:
999 (WebKit::WebChromeClient::showAirPlayRoutePicker):
1000 * WebProcess/WebPage/WebPage.cpp:
1001 (WebKit::WebPage::touchEvent):
1002 (WebKit::WebPage::touchEventSyncForTesting):
1003 * WebProcess/WebPage/WebPage.h:
1004 * WebProcess/WebPage/ios/WebPageIOS.mm:
1005 (WebKit::WebPage::rectForElementAtInteractionLocation):
1006 (WebKit::WebPage::handleTap):
1008 2014-03-27 Benjamin Poulain <bpoulain@apple.com>
1010 [WK2][iOS] <rdar://problem/16414684> WKWebView should draw a white background before the page loads
1011 https://bugs.webkit.org/show_bug.cgi?id=130873
1013 Reviewed by Simon Fraser.
1015 * UIProcess/API/Cocoa/WKWebView.mm:
1016 (-[WKWebView initWithFrame:configuration:]):
1018 2014-03-27 Benjamin Poulain <bpoulain@apple.com>
1020 [iOS][WK2] Compute a good exposed rect when scaling WKContentView
1021 https://bugs.webkit.org/show_bug.cgi?id=130761
1023 Reviewed by Simon Fraser.
1025 Add a simple heuristic to improve tiling while zooming. In theory we could take the zoom
1026 center and scaleRate to split the speed between scrolling and pinching. In practice,
1027 zoom is transitory and is not as predictable as scrolling, so this patch just does a very
1029 -When zooming in, do not expand coverage.
1030 -When zooming out, add half a tile size on every side.
1032 * Shared/VisibleContentRectUpdateInfo.cpp:
1033 (WebKit::VisibleContentRectUpdateInfo::encode):
1034 (WebKit::VisibleContentRectUpdateInfo::decode):
1035 * Shared/VisibleContentRectUpdateInfo.h:
1036 (WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo):
1037 (WebKit::VisibleContentRectUpdateInfo::timestamp):
1038 (WebKit::VisibleContentRectUpdateInfo::horizontalVelocity):
1039 (WebKit::VisibleContentRectUpdateInfo::verticalVelocity):
1040 (WebKit::VisibleContentRectUpdateInfo::scaleChangeRate):
1041 * UIProcess/ios/WKContentView.mm:
1042 (WebKit::HistoricalVelocityData::VelocityData::VelocityData):
1043 (WebKit::HistoricalVelocityData::velocityForNewData):
1044 (WebKit::HistoricalVelocityData::append):
1045 (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
1046 * WebProcess/WebPage/ios/WebPageIOS.mm:
1048 (WebKit::adjustExposedRectForBoundedScale):
1049 When zooming past the maximum size, adjust the exposed rect to continue tiling the area
1050 at maximum size. Otherwise, we tile a tiny area, and have to retile larger when the animation
1051 pull back the view to maximum scale.
1053 (WebKit::adjustVelocityDataForBoundedScale):
1054 Since we do not split the velocity from scrolling from the scaling, just clear the velocity when zooming.
1055 Also clear the scaleChangeRate when the scale is out of bounds. There is no reason to add tiles for
1058 (WebKit::WebPage::updateVisibleContentRects):
1060 2014-03-27 Anders Carlsson <andersca@apple.com>
1062 Add _ prefix to WKRemoteObjectRegistery and WKRemoteObjectInterface
1063 https://bugs.webkit.org/show_bug.cgi?id=130868
1065 Reviewed by Sam Weinig.
1067 * Shared/API/Cocoa/RemoteObjectRegistry.h:
1068 * Shared/API/Cocoa/RemoteObjectRegistry.mm:
1069 (WebKit::RemoteObjectRegistry::RemoteObjectRegistry):
1070 * Shared/API/Cocoa/WKRemoteObject.h:
1071 * Shared/API/Cocoa/WKRemoteObject.mm:
1072 (-[WKRemoteObject _initWithObjectRegistry:interface:]):
1073 * Shared/API/Cocoa/WKRemoteObjectCoder.h:
1074 * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
1075 (-[WKRemoteObjectDecoder initWithInterface:rootObjectDictionary:WebKit::]):
1076 * Shared/API/Cocoa/WKRemoteObjectInterface.h:
1077 * Shared/API/Cocoa/WKRemoteObjectInterface.mm:
1078 (isContainerClass): Deleted.
1079 (propertyListClasses): Deleted.
1080 (allowedArgumentClassesForMethod): Deleted.
1081 (initializeAllowedArgumentClasses): Deleted.
1082 (-[WKRemoteObjectInterface initWithProtocol:identifier:]): Deleted.
1083 (+[WKRemoteObjectInterface remoteObjectInterfaceWithProtocol:]): Deleted.
1084 (-[WKRemoteObjectInterface description]): Deleted.
1085 (classesForSelectorArgument): Deleted.
1086 (-[WKRemoteObjectInterface classesForSelector:argumentIndex:]): Deleted.
1087 (-[WKRemoteObjectInterface setClasses:forSelector:argumentIndex:]): Deleted.
1088 (methodArgumentTypeEncodingForSelector): Deleted.
1089 (-[WKRemoteObjectInterface _methodSignatureForSelector:]): Deleted.
1090 (-[WKRemoteObjectInterface _allowedArgumentClassesForSelector:]): Deleted.
1091 * Shared/API/Cocoa/WKRemoteObjectRegistry.h:
1092 * Shared/API/Cocoa/WKRemoteObjectRegistry.mm:
1093 (-[WKRemoteObjectRegistry registerExportedObject:interface:]): Deleted.
1094 (-[WKRemoteObjectRegistry unregisterExportedObject:interface:]): Deleted.
1095 (-[WKRemoteObjectRegistry remoteObjectProxyWithInterface:]): Deleted.
1096 (-[WKRemoteObjectRegistry _initWithMessageSender:IPC::]): Deleted.
1097 (-[WKRemoteObjectRegistry _invalidate]): Deleted.
1098 (-[WKRemoteObjectRegistry _sendInvocation:interface:]): Deleted.
1099 (-[WKRemoteObjectRegistry WebKit::]): Deleted.
1100 (-[WKRemoteObjectRegistry _invokeMethod:]): Deleted.
1101 (-[WKRemoteObjectRegistry _invokeMessageWithInterfaceIdentifier:encodedInvocation:]): Deleted.
1102 * Shared/API/Cocoa/_WKRemoteObjectInterface.h: Copied from Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectInterface.h.
1103 * Shared/API/Cocoa/_WKRemoteObjectInterface.mm: Copied from Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectInterface.mm.
1105 (propertyListClasses):
1106 (allowedArgumentClassesForMethod):
1107 (initializeAllowedArgumentClasses):
1108 (-[_WKRemoteObjectInterface initWithProtocol:identifier:]):
1109 (+[_WKRemoteObjectInterface remoteObjectInterfaceWithProtocol:]):
1110 (-[_WKRemoteObjectInterface description]):
1111 (classesForSelectorArgument):
1112 (-[_WKRemoteObjectInterface classesForSelector:argumentIndex:]):
1113 (-[_WKRemoteObjectInterface setClasses:forSelector:argumentIndex:]):
1114 (methodArgumentTypeEncodingForSelector):
1115 (-[_WKRemoteObjectInterface _methodSignatureForSelector:]):
1116 (-[_WKRemoteObjectInterface _allowedArgumentClassesForSelector:]):
1117 * Shared/API/Cocoa/_WKRemoteObjectInterfaceInternal.h: Renamed from Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectInterfaceInternal.h.
1118 * Shared/API/Cocoa/_WKRemoteObjectRegistry.h: Copied from Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectRegistry.h.
1119 * Shared/API/Cocoa/_WKRemoteObjectRegistry.mm: Copied from Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectRegistry.mm.
1120 (-[_WKRemoteObjectRegistry registerExportedObject:interface:]):
1121 (-[_WKRemoteObjectRegistry unregisterExportedObject:interface:]):
1122 (-[_WKRemoteObjectRegistry remoteObjectProxyWithInterface:]):
1123 (-[_WKRemoteObjectRegistry _initWithMessageSender:IPC::]):
1124 (-[_WKRemoteObjectRegistry _invalidate]):
1125 (-[_WKRemoteObjectRegistry _sendInvocation:interface:]):
1126 (-[_WKRemoteObjectRegistry WebKit::]):
1127 (-[_WKRemoteObjectRegistry _invokeMethod:]):
1128 (-[_WKRemoteObjectRegistry _invokeMessageWithInterfaceIdentifier:encodedInvocation:]):
1129 * Shared/API/Cocoa/_WKRemoteObjectRegistryInternal.h: Renamed from Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectRegistryInternal.h.
1130 * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
1131 (-[WKBrowsingContextController _remoteObjectRegistry]):
1132 (-[WKBrowsingContextController remoteObjectRegistry]): Deleted.
1133 * UIProcess/API/Cocoa/WKBrowsingContextControllerPrivate.h:
1134 * UIProcess/API/Cocoa/WKWebView.mm:
1135 (-[WKWebView _remoteObjectRegistry]):
1136 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1137 * WebKit2.xcodeproj/project.pbxproj:
1138 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInBrowserContextControllerToBeRemoved.mm: Copied from Source/WebKit2/Shared/API/Cocoa/WKRemoteObject.h.
1139 (-[WKWebProcessPlugInBrowserContextController remoteObjectRegistry]):
1140 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
1141 (-[WKWebProcessPlugInBrowserContextController _remoteObjectRegistry]):
1142 (-[WKWebProcessPlugInBrowserContextController remoteObjectRegistry]): Deleted.
1143 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextControllerPrivate.h:
1145 2014-03-27 Commit Queue <commit-queue@webkit.org>
1147 Unreviewed, rolling out r166360.
1148 https://bugs.webkit.org/show_bug.cgi?id=130869
1150 Seems to have broken PLT (Requested by ap on #webkit).
1154 "Connection::dispatchOneMessage() can be re-entered while
1155 handling Cmd-key menu"
1156 https://bugs.webkit.org/show_bug.cgi?id=130767
1157 http://trac.webkit.org/changeset/166360
1159 2014-03-27 Sam Weinig <sam@webkit.org>
1161 Support dynamic layer hosting context changes
1162 <rdar://problem/16278019>
1163 https://bugs.webkit.org/show_bug.cgi?id=130863
1165 Reviewed by Anders Carlsson.
1167 * UIProcess/API/mac/WKView.mm:
1168 (-[WKView addWindowObserversForWindow:]):
1169 (-[WKView removeWindowObservers]):
1170 (-[WKView _windowDidChangeLayerHosting:]):
1171 * UIProcess/WebPageProxy.cpp:
1172 (WebKit::WebPageProxy::layerHostingModeDidChange):
1173 * UIProcess/WebPageProxy.h:
1175 2014-03-27 Simon Fraser <simon.fraser@apple.com>
1177 Don't leak the WKBrowsingContextController
1178 https://bugs.webkit.org/show_bug.cgi?id=130815
1180 Reviewed by Tim Horton.
1182 Use adoptNS to avoid leaking the WKBrowsingContextController.
1184 * UIProcess/ios/WKContentView.mm:
1185 (-[WKContentView browsingContextController]):
1187 2014-03-27 Joseph Pecoraro <pecoraro@apple.com>
1189 Web Inspector: Give WebProcess a proxy application entitlement
1190 https://bugs.webkit.org/show_bug.cgi?id=130806
1192 Reviewed by Timothy Hatcher.
1194 * Configurations/WebContent-iOS.entitlements:
1196 2014-03-27 Anders Carlsson <andersca@apple.com>
1198 Add reload and reloadFromOrigin as API
1199 https://bugs.webkit.org/show_bug.cgi?id=130858
1201 Reviewed by Simon Fraser.
1203 * UIProcess/API/Cocoa/WKWebView.h:
1204 * UIProcess/API/Cocoa/WKWebView.mm:
1205 (-[WKWebView reload]):
1206 (-[WKWebView reloadFromOrigin]):
1207 (-[WKWebView validateUserInterfaceItem:]):
1208 (-[WKWebView reload:]):
1209 (-[WKWebView reloadFromOrigin:]):
1211 2014-03-27 Anders Carlsson <andersca@apple.com>
1213 Rename WKFrameHandle to _WKFrameHandle
1214 https://bugs.webkit.org/show_bug.cgi?id=130847
1216 Reviewed by Tim Horton.
1218 * Shared/API/Cocoa/_WKFrameHandle.h: Renamed from Source/WebKit2/Shared/API/Cocoa/WKFrameHandle.h.
1219 * Shared/API/Cocoa/_WKFrameHandle.mm: Renamed from Source/WebKit2/Shared/API/Cocoa/WKFrameHandle.mm.
1220 (-[_WKFrameHandle dealloc]):
1221 (-[_WKFrameHandle isEqual:]):
1222 (-[_WKFrameHandle hash]):
1223 (-[_WKFrameHandle _frameID]):
1224 (-[_WKFrameHandle copyWithZone:]):
1225 (+[_WKFrameHandle supportsSecureCoding]):
1226 (-[_WKFrameHandle initWithCoder:]):
1227 (-[_WKFrameHandle encodeWithCoder:]):
1228 (-[_WKFrameHandle API::]):
1229 * Shared/API/Cocoa/_WKFrameHandleInternal.h: Renamed from Source/WebKit2/Shared/API/Cocoa/WKFrameHandleInternal.h.
1231 * Shared/Cocoa/APIObject.mm:
1232 (API::Object::newObject):
1233 * WebKit2.xcodeproj/project.pbxproj:
1234 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.h:
1235 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm:
1236 (+[WKWebProcessPlugInFrame lookUpFrameFromHandle:]):
1237 (-[WKWebProcessPlugInFrame handle]):
1238 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFramePrivate.h:
1240 2014-03-27 Alexey Proskuryakov <ap@apple.com>
1242 Connection::dispatchOneMessage() can be re-entered while handling Cmd-key menu
1243 equivalents, ASSERT(!_data->_keyDownEventBeingResent)
1244 https://bugs.webkit.org/show_bug.cgi?id=130767
1245 <rdar://problem/16307487>
1247 Reviewed by Darin Adler.
1249 * Shared/WebKit2Initialize.cpp: (WebKit::InitializeWebKit2): Added NSModalPanelRunLoopMode
1250 to RunLoop event source and timer modes.
1252 2014-03-27 Jae Hyun Park <jaepark@webkit.org>
1254 Remove LayerTreeContextCairo.cpp
1255 https://bugs.webkit.org/show_bug.cgi?id=130807
1257 Reviewed by Martin Robinson.
1259 * Shared/cairo/LayerTreeContextCairo.cpp: Removed.
1261 2014-03-27 Maciej Florek <m.florek@samsung.com>
1263 [EFL][WK2] Add tests of the set process model API
1264 https://bugs.webkit.org/show_bug.cgi?id=130830
1266 Reviewed by Gyuyoung Kim.
1268 Implement unit tests to check, if process model API works
1269 properly. When process model is set to EWK_PROCESS_MODEL_SHARED_SECONDARY,
1270 there should be only one WebProcess. In case of EWK_PROCESS_MODEL_MULTIPLE_SECONDARY
1271 setting, each WebView should have own process, as well as the network process
1274 * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.cpp:
1275 (EWK2UnitTest::EWK2UnitTestBase::EWK2UnitTestBase):
1276 (EWK2UnitTest::EWK2UnitTestBase::SetUp):
1277 * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.h:
1278 * UIProcess/API/efl/tests/test_ewk2_context.cpp:
1279 (EWK2ContextTestMultipleProcesses::EWK2ContextTestMultipleProcesses):
1282 2014-03-27 Commit Queue <commit-queue@webkit.org>
1284 Unreviewed, rolling out r166296 and r166331.
1285 https://bugs.webkit.org/show_bug.cgi?id=130822
1287 caused some crashes and frequent assertion failures, and the
1288 fix is going to take a little while (Requested by thorton on
1291 Reverted changesets:
1293 "[iOS WebKit2] Flush all surfaces after painting into all of
1294 them, instead of after painting into each one"
1295 https://bugs.webkit.org/show_bug.cgi?id=130768
1296 http://trac.webkit.org/changeset/166296
1298 "Assertion failure in RemoteLayerBackingStore::flush"
1299 https://bugs.webkit.org/show_bug.cgi?id=130810
1300 http://trac.webkit.org/changeset/166331
1302 2014-03-26 Tim Horton <timothy_horton@apple.com>
1304 Blind speculative iOS build fix.
1306 * WebProcess/WebPage/ios/WebPageIOS.mm:
1307 (WebKit::WebPage::viewportConfigurationChanged):
1309 2014-03-26 Benjamin Poulain <bpoulain@apple.com>
1311 [iOS][WK2] <rdar://problem/16265272> REGRESSION (WebKit2): Some pages appear blank until you scroll
1312 https://bugs.webkit.org/show_bug.cgi?id=130819
1314 Reviewed by Tim Horton.
1316 When loading a new page, we never define the unobscured rect and exposed rect on the new frame.
1317 As a result, there is nothing to render.
1319 It uses to work thanks to dumb luck and a bug in Safari updating the visibleContentRects from
1320 the UIProcess. Now that the bug is gone, "dumb luck" is not reliable enough to get the content rects :)
1322 What this patch does is save if we have ever received new rects from the UI. If we have not, create them
1323 based on the minimum layout size. This works because we know Safari shows the minimum layout size by default
1324 and will tell us if it changes the obscured rects.
1326 * WebProcess/WebPage/WebPage.cpp:
1327 (WebKit::WebPage::WebPage):
1328 (WebKit::WebPage::didCommitLoad):
1329 * WebProcess/WebPage/WebPage.h:
1330 * WebProcess/WebPage/ios/WebPageIOS.mm:
1331 (WebKit::WebPage::viewportConfigurationChanged):
1332 (WebKit::WebPage::updateVisibleContentRects):
1334 2014-03-26 Anders Carlsson <andersca@apple.com>
1336 Add a _WKScriptWorld class
1337 https://bugs.webkit.org/show_bug.cgi?id=130817
1339 Reviewed by Dan Bernstein.
1341 * UIProcess/API/Cocoa/_WKScriptWorld.h: Added.
1342 * UIProcess/API/Cocoa/_WKScriptWorld.mm: Added.
1344 (+[_WKScriptWorld defaultWorld]):
1345 (-[_WKScriptWorld init]):
1346 (-[_WKScriptWorld _initWithWorldID:]):
1347 * WebKit2.xcodeproj/project.pbxproj:
1349 2014-03-26 Anders Carlsson <andersca@apple.com>
1351 Rename a delegate method to -webView:didFinishNavigation:
1352 https://bugs.webkit.org/show_bug.cgi?id=130814
1354 Reviewed by Sam Weinig.
1356 * UIProcess/API/Cocoa/WKNavigationDelegate.h:
1357 * UIProcess/Cocoa/NavigationState.h:
1358 * UIProcess/Cocoa/NavigationState.mm:
1359 (WebKit::NavigationState::setNavigationDelegate):
1360 (WebKit::NavigationState::LoaderClient::didFinishLoadForFrame):
1362 2014-03-26 Tim Horton <timothy_horton@apple.com>
1364 [iOS WebKit2] Crashes on swipe
1365 <rdar://problem/16440867>
1367 Reviewed by Benjamin Poulain.
1369 * UIProcess/ios/ViewGestureControllerIOS.mm:
1370 (WebKit::ViewGestureController::beginSwipeGesture):
1371 Get the IOSurfaceRef from the WebCore::IOSurface.
1373 2014-03-26 Simon Fraser <simon.fraser@apple.com>
1375 Fix the build: include UIKit headers inside the iOS #ifdef.
1377 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
1379 2014-03-26 Simon Fraser <simon.fraser@apple.com>
1381 Hook up -webkit-overflow-scrolling:touch for iOS WK2
1382 https://bugs.webkit.org/show_bug.cgi?id=130809
1384 Reviewed by Tim Horton.
1386 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h:
1387 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
1388 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::updateAfterChildren):
1389 Set the content size of the UIScrollVIew based on the geometry.
1390 * UIProcess/ios/RemoteLayerTreeHostIOS.mm:
1391 (WebKit::RemoteLayerTreeHost::createLayer): Make a UIScrollView if the
1392 layer properties tell us that we have the scrolling behavior.
1393 * UIProcess/ios/WKContentView.mm:
1394 (-[WKContentView initWithFrame:context:WebKit::configuration:WebKit::webView:]):
1395 We need to allow user interaction in the _rootContentView so that events get to
1396 nested UIScrollViews (this could be optimized in future).
1397 * UIProcess/mac/RemoteLayerTreeHost.h:
1398 * UIProcess/mac/RemoteLayerTreeHost.mm:
1399 (WebKit::RemoteLayerTreeHost::updateLayerTree):
1400 (WebKit::RemoteLayerTreeHost::createLayer): Need to pass RemoteLayerTreeTransaction::LayerProperties
1401 in so we can get at the custom behavior.
1403 2014-03-26 Anders Carlsson <andersca@apple.com>
1405 Add -[WKWebView stopLoading]
1406 https://bugs.webkit.org/show_bug.cgi?id=130812
1408 Reviewed by Tim Horton.
1410 * UIProcess/API/Cocoa/WKWebView.h:
1411 * UIProcess/API/Cocoa/WKWebView.mm:
1412 (-[WKWebView stopLoading]):
1414 2014-03-26 Tim Horton <timothy_horton@apple.com>
1416 Assertion failure in RemoteLayerBackingStore::flush
1417 https://bugs.webkit.org/show_bug.cgi?id=130810
1418 <rdar://problem/16439276>
1420 Reviewed by Simon Fraser.
1422 * Shared/mac/RemoteLayerBackingStore.mm:
1423 (RemoteLayerBackingStore::flush):
1424 We don't always have backing store to flush, if platformCALayerDrawsContent() is false.
1425 We also can't assert that we have a back surface, because the very first paint will not.
1427 2014-03-26 Andy Estes <aestes@apple.com>
1429 [Cocoa] Expose DownloadClient::didFail() and DownloadClient::didCancel()
1430 https://bugs.webkit.org/show_bug.cgi?id=130805
1432 Reviewed by Dan Bernstein.
1434 * UIProcess/API/Cocoa/_WKDownloadDelegate.h:
1435 * UIProcess/Cocoa/DownloadClient.h:
1436 * UIProcess/Cocoa/DownloadClient.mm:
1437 (WebKit::DownloadClient::DownloadClient):
1438 (WebKit::DownloadClient::didFail):
1439 (WebKit::DownloadClient::didCancel):
1441 2014-03-26 Cody Krieger <cjk@apple.com>
1443 -[WKWebProcessPlugInNodeHandle HTMLInputElementIsUserEdited] and -HTMLTextAreaElementIsUserEdited do not return the correct values.
1445 https://bugs.webkit.org/show_bug.cgi?id=130804
1447 Reviewed by Dan Bernstein.
1449 The existing implementations of these methods are mis-cased
1450 ("HTMLInputELementIsUserEdited" and "HTMLTextAreaELementIsUserEdited" —
1451 note the "EL" in both cases). This results in us getting
1452 auto-synthesized getters for the HTMLInputElementIsUserEdited and
1453 HTMLTextAreaElementIsUserEdited properties, which will return NO
1456 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.mm:
1457 Fix the capitalization of -HTMLInputElementIsUserEdited and
1458 -HTMLTextAreaElementIsUserEdited.
1460 2014-03-26 Andy Estes <aestes@apple.com>
1462 [Cocoa] Expose DownloadProxy::cancel()
1463 https://bugs.webkit.org/show_bug.cgi?id=130799
1465 Reviewed by Dan Bernstein.
1467 * UIProcess/API/Cocoa/_WKDownload.h:
1468 * UIProcess/API/Cocoa/_WKDownload.mm:
1469 (-[_WKDownload cancel]):
1471 2014-03-26 Timothy Hatcher <timothy@apple.com>
1473 Propagate the hiddenFromInspector flag on ResourceRequest in
1474 places when a new request a made or passed between processes.
1476 https://bugs.webkit.org/show_bug.cgi?id=130741
1478 Reviewed by Joseph Pecoraro.
1480 * NetworkProcess/NetworkResourceLoader.cpp:
1481 (WebKit::NetworkResourceLoader::continueWillSendRequest): Use updateFromDelegatePreservingOldProperties.
1482 * Shared/WebCoreArgumentCoders.cpp:
1483 (IPC::ArgumentCoder<ResourceRequest>::encode): Added hiddenFromInspector support.
1484 (IPC::ArgumentCoder<ResourceRequest>::decode): Ditto.
1485 * WebProcess/InjectedBundle/InjectedBundlePageResourceLoadClient.cpp:
1486 (WebKit::InjectedBundlePageResourceLoadClient::willSendRequestForFrame): Ditto.
1488 2014-03-26 Andy Estes <aestes@apple.com>
1490 [Cocoa] Expose DownloadProxy::request()
1491 https://bugs.webkit.org/show_bug.cgi?id=130796
1493 Reviewed by Anders Carlsson.
1495 * UIProcess/API/Cocoa/_WKDownload.h:
1496 * UIProcess/API/Cocoa/_WKDownload.mm:
1497 (-[_WKDownload request]):
1499 2014-03-26 Anders Carlsson <andersca@apple.com>
1501 Pass a real FrameLoadRequest to Chrome::createWindow
1502 https://bugs.webkit.org/show_bug.cgi?id=130795
1504 Reviewed by Dan Bernstein.
1506 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1507 (WebKit::WebFrameLoaderClient::dispatchCreatePage):
1509 2014-03-26 Jeremy Jones <jeremyj@apple.com>
1511 Implement hasLiveStreamingContent property in WebAVPlayerController
1512 https://bugs.webkit.org/show_bug.cgi?id=128684
1514 Reviewed by Simon Fraser.
1516 Plumb through the seekable ranges to the fullscreen interface.
1518 * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
1519 Add declaration for setSeekableRangesVector()
1521 * UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in:
1522 Add interface SetSeekableRangesVector()
1524 * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
1525 (WebKit::WebVideoFullscreenManagerProxy::setSeekableRangesVector):
1526 Add setSeekableRangesVector that translates the vector into a TimeRanges and calls setSeekableRanges()
1528 * WebProcess/ios/WebVideoFullscreenManager.h:
1529 Add setSeekableRanges()
1531 * WebProcess/ios/WebVideoFullscreenManager.mm:
1532 (WebKit::WebVideoFullscreenManager::setSeekableRanges):
1533 setSeekableRanges() converts TimeRanges to Vector and calls SetSeekableRangesVector()
1535 2014-03-26 Simon Fraser <simon.fraser@apple.com>
1537 Add a custom behavior flag to GraphicsLayer, piped down to PlatformCALayer, for scrolling layers
1538 https://bugs.webkit.org/show_bug.cgi?id=130778
1540 Reviewed by Tim Horton.
1542 Make it possible to put a "custom behavior" flag on a layer so that,
1543 with UI-side compositing, we know to create a specific type of
1544 layer or view for that GraphicsLayer.
1546 * Shared/mac/RemoteLayerTreeTransaction.h:
1547 * Shared/mac/RemoteLayerTreeTransaction.mm:
1548 (WebKit::RemoteLayerTreeTransaction::LayerProperties::LayerProperties):
1549 (WebKit::RemoteLayerTreeTransaction::LayerProperties::encode):
1550 (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
1551 (WebKit::dumpChangedLayers):
1552 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
1553 (PlatformCALayerRemote::customBehavior):
1554 (PlatformCALayerRemote::updateCustomBehavior):
1555 * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
1557 2014-03-26 Zoltan Horvath <zoltan@webkit.org>
1559 [CSS Shapes] Remove shape-inside support
1560 https://bugs.webkit.org/show_bug.cgi?id=130698
1562 Reviewed by David Hyatt.
1564 * Configurations/FeatureDefines.xcconfig:
1566 2014-03-26 Tim Horton <timothy_horton@apple.com>
1568 [iOS WebKit2] Flush all surfaces after painting into all of them, instead of after painting into each one
1569 https://bugs.webkit.org/show_bug.cgi?id=130768
1570 <rdar://problem/16421471>
1572 Reviewed by Simon Fraser.
1574 * Shared/mac/RemoteLayerBackingStore.h:
1575 Add flush(), which synchronously flushes painting operations on the underlying backing store.
1576 Factor clearBackingStore() out of ensureBackingStore/display, which releases our reference to underlying backing store.
1577 Add two members for storing the back surface and front buffer context until flush() is called.
1578 - We need to keep the back surface alive because the CGImageRef created from it is referenced by
1579 the front surface's drawing queue, and won't be freed until said queue is flushed. If we release
1580 the back surface (and its associated CGContextRef) *before* the CGImageRef is freed, we will
1581 do an expensive readback of the surface.
1582 - When not using accelerated drawing, we need to keep the front buffer's CGContextRef around
1583 until the flush occurs so that we can avoid re-creating it in order to perform the flush. This
1584 happens automatically in the accelerated drawing case via WebCore::IOSurface.
1586 * Shared/mac/RemoteLayerBackingStore.mm:
1587 (RemoteLayerBackingStore::ensureBackingStore):
1588 (RemoteLayerBackingStore::clearBackingStore):
1589 (RemoteLayerBackingStore::display):
1590 Factor clearBackingStore() out of ensureBackingStore() and display().
1591 Update a comment about the above performance gotcha.
1592 Store the current back surface/front buffer context.
1594 (RemoteLayerBackingStore::drawInContext):
1595 Don't flush the context immediately after painting.
1597 (RemoteLayerBackingStore::applyBackingStoreToLayer):
1598 Move things around to reduce duplicated code.
1600 (RemoteLayerBackingStore::flush):
1601 Flush the current front surface/buffer's context.
1602 Clear the new pending-flush members.
1604 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
1605 (WebKit::flushBackingStoreChangesInTransaction):
1606 (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
1607 Crawl through all of the valid changed backing stores in the transaction and flush them.
1608 Remove a completely useless assertion.
1610 2014-03-25 Simon Fraser <simon.fraser@apple.com>
1612 Add a new type of scrolling tree node for overflow scrolling
1613 https://bugs.webkit.org/show_bug.cgi?id=130763
1615 Reviewed by Tim Horton.
1617 Prepare for overflow scrolling via the scrolling tree by adding
1618 a new scrolling node type for overflow:scroll nodes. Mostly
1619 this is a new ScrollingNodeType that gets mapped to the same
1620 scrolling state nodes and scrolling nodes, but iOS creates
1621 state and scrolling nodes specific to overflow:scroll.
1623 Change the type checking on nodes to use virtual functions instead
1624 of just checking the node type, to allow the macros to work with
1625 the new scrolling node type.
1627 * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
1628 (WebKit::encodeNodeAndDescendants):
1629 (WebKit::RemoteScrollingCoordinatorTransaction::decode):
1630 * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
1631 (WebKit::RemoteScrollingCoordinatorProxy::connectStateNodeLayers):
1632 * UIProcess/Scrolling/RemoteScrollingTree.cpp:
1633 (WebKit::RemoteScrollingTree::createNode):
1634 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h: Copied from Source/WebCore/page/scrolling/mac/ScrollingTreeFixedNode.h.
1635 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm: Copied from Source/WebCore/page/scrolling/mac/ScrollingTreeFixedNode.h.
1636 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::create):
1637 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::ScrollingTreeOverflowScrollingNodeIOS):
1638 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::~ScrollingTreeOverflowScrollingNodeIOS):
1639 * UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm:
1640 (WebKit::RemoteScrollingCoordinatorProxy::connectStateNodeLayers):
1641 * WebKit2.xcodeproj/project.pbxproj:
1643 2014-03-26 Zan Dobersek <zdobersek@igalia.com>
1645 Unreviewed. Removing the remaining Automake cruft.
1647 * GNUmakefile.list.am: Removed.
1649 2014-03-25 Pratik Solanki <psolanki@apple.com>
1651 Remove PLATFORM(IOS) from NetworkProcessMac.mm
1652 https://bugs.webkit.org/show_bug.cgi?id=130751
1654 Reviewed by Alexey Proskuryakov.
1656 Code in NetworkProcessMac.mm is guarded by PLATFORM(MAC) and so is not compiled on iOS.
1657 Having PLATFORM(IOS) code in this file is unnecessary and confusing.
1659 * NetworkProcess/mac/NetworkProcessMac.mm:
1660 (WebKit::NetworkProcess::initializeProcessName):
1661 (WebKit::overrideSystemProxies):
1662 (WebKit::NetworkProcess::platformInitializeNetworkProcess):
1664 2014-03-25 Anders Carlsson <andersca@apple.com>
1666 Add a UI delegate callback for handling window.open
1667 https://bugs.webkit.org/show_bug.cgi?id=130757
1669 Reviewed by Sam Weinig.
1671 * UIProcess/API/Cocoa/WKUIDelegate.h:
1672 * UIProcess/API/Cocoa/WKWebView.mm:
1673 * UIProcess/API/Cocoa/WKWebViewInternal.h:
1674 * UIProcess/Cocoa/UIClient.h:
1675 * UIProcess/Cocoa/UIClient.mm:
1676 (WebKit::UIClient::setDelegate):
1677 (WebKit::UIClient::createNewPage):
1679 2014-03-25 Anders Carlsson <andersca@apple.com>
1681 Move stopLoading: back for now.
1683 * UIProcess/API/Cocoa/WKWebView.h:
1684 * UIProcess/API/Cocoa/WKWebView.mm:
1685 (-[WKWebView stopLoading:]):
1687 2014-03-25 Anders Carlsson <andersca@apple.com>
1689 Change toolbarVisibility back to toolbarsVisibility
1690 https://bugs.webkit.org/show_bug.cgi?id=130749
1692 Reviewed by Tim Horton.
1694 * UIProcess/API/Cocoa/WKWindowFeatures.h:
1695 * UIProcess/API/Cocoa/WKWindowFeatures.mm:
1696 (-[WKWindowFeatures _initWithWindowFeatures:WebCore::]):
1698 2014-03-25 Anders Carlsson <andersca@apple.com>
1700 Pass the source frame to the CreateNewPage message
1701 https://bugs.webkit.org/show_bug.cgi?id=130752
1703 Reviewed by Tim Horton.
1705 * UIProcess/API/APIUIClient.h:
1706 (API::UIClient::createNewPage):
1707 * UIProcess/API/C/WKPage.cpp:
1708 (WKPageSetPageUIClient):
1709 * UIProcess/WebPageProxy.cpp:
1710 (WebKit::WebPageProxy::createNewPage):
1711 * UIProcess/WebPageProxy.h:
1712 * UIProcess/WebPageProxy.messages.in:
1713 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1714 (WebKit::WebChromeClient::createWindow):
1716 2014-03-25 Anders Carlsson <andersca@apple.com>
1718 Add a WebFrame::fromCoreFrame static member function and use it where possible
1719 https://bugs.webkit.org/show_bug.cgi?id=130744
1721 Reviewed by Tim Horton.
1723 * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
1724 (WebKit::GeolocationPermissionRequestManager::startRequestForGeolocation):
1725 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
1726 (WebKit::InjectedBundleNodeHandle::documentFrame):
1727 (WebKit::InjectedBundleNodeHandle::htmlFrameElementContentFrame):
1728 (WebKit::InjectedBundleNodeHandle::htmlIFrameElementContentFrame):
1729 * WebProcess/InjectedBundle/InjectedBundle.cpp:
1730 (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
1731 * WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.cpp:
1732 (WebKit::InjectedBundleDOMWindowExtension::frame):
1733 * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1734 (WebKit::InjectedBundleHitTestResult::frame):
1735 (WebKit::InjectedBundleHitTestResult::targetFrame):
1736 * WebProcess/Plugins/PluginView.cpp:
1738 (WebKit::PluginView::performFrameLoadURLRequest):
1739 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1740 (WebKit::WebChromeClient::focusedElementChanged):
1741 (WebKit::WebChromeClient::focusedFrameChanged):
1742 (WebKit::WebChromeClient::runBeforeUnloadConfirmPanel):
1743 (WebKit::WebChromeClient::runJavaScriptAlert):
1744 (WebKit::WebChromeClient::runJavaScriptConfirm):
1745 (WebKit::WebChromeClient::runJavaScriptPrompt):
1746 (WebKit::WebChromeClient::print):
1747 (WebKit::WebChromeClient::exceededDatabaseQuota):
1748 (WebKit::WebChromeClient::runOpenPanel):
1749 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1750 (WebKit::WebEditorClient::textFieldDidBeginEditing):
1751 (WebKit::WebEditorClient::textFieldDidEndEditing):
1752 (WebKit::WebEditorClient::textDidChangeInTextField):
1753 (WebKit::WebEditorClient::textDidChangeInTextArea):
1754 (WebKit::WebEditorClient::doTextFieldCommandFromEvent):
1755 (WebKit::WebEditorClient::textWillBeDeletedInTextField):
1756 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1757 (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1758 (WebKit::WebFrameLoaderClient::dispatchWillSendSubmitEvent):
1759 (WebKit::WebFrameLoaderClient::dispatchWillSubmitForm):
1760 * WebProcess/WebPage/WebFrame.cpp:
1761 (WebKit::WebFrame::fromCoreFrame):
1762 (WebKit::WebFrame::contentsAsString):
1763 (WebKit::WebFrame::parentFrame):
1764 (WebKit::WebFrame::childFrames):
1765 (WebKit::WebFrame::frameForContext):
1766 (WebKit::WebFrame::webArchiveData):
1767 * WebProcess/WebPage/WebFrame.h:
1769 2014-03-25 Jeffrey Pfau <jpfau@apple.com>
1771 [WK2] Schemes registered as cache partitioned are not properly registered in new web processes
1772 https://bugs.webkit.org/show_bug.cgi?id=130739
1774 Reviewed by Anders Carlsson.
1776 * WebProcess/WebProcess.cpp:
1777 (WebKit::WebProcess::initializeWebProcess):
1779 2014-03-25 Joseph Pecoraro <pecoraro@apple.com>
1781 [iOS] Inspector View Indication Support
1782 https://bugs.webkit.org/show_bug.cgi?id=130709
1784 Reviewed by Simon Fraser.
1786 * UIProcess/ios/WKContentView.h:
1787 * UIProcess/ios/WKContentView.mm:
1788 (-[WKInspectorIndicationView initWithFrame:]):
1789 (-[WKContentView isShowingInspectorIndication]):
1790 (-[WKContentView setShowingInspectorIndication:]):
1791 (-[WKContentView _didCommitLayerTree:WebKit::]):
1792 When indicating include a simple tinted UIView over the content.
1794 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1795 * UIProcess/API/Cocoa/WKWebView.mm:
1796 (-[WKWebView _showInspectorIndication]):
1797 (-[WKWebView _hideInspectorIndication]):
1798 Have the content view show or hide an indication.
1800 * UIProcess/PageClient.h:
1801 * UIProcess/ios/PageClientImplIOS.h:
1802 * UIProcess/ios/PageClientImplIOS.mm:
1803 (WebKit::PageClientImpl::showInspectorIndication):
1804 (WebKit::PageClientImpl::hideInspectorIndication):
1805 * UIProcess/WebPageProxy.h:
1806 * UIProcess/WebPageProxy.messages.in:
1807 * UIProcess/ios/WebPageProxyIOS.mm:
1808 (WebKit::WebPageProxy::showInspectorIndication):
1809 (WebKit::WebPageProxy::hideInspectorIndication):
1810 Pass WebProcess indication message up to the WKWebView.
1812 * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
1813 (WebKit::WebInspectorClient::indicate):
1814 (WebKit::WebInspectorClient::hideIndication):
1815 * WebProcess/WebCoreSupport/WebInspectorClient.h:
1816 * WebProcess/WebPage/WebPage.h:
1817 * WebProcess/WebPage/ios/WebPageIOS.mm:
1818 (WebKit::WebPage::indicate):
1819 (WebKit::WebPage::hideIndication):
1820 Pass WebCore / remote inspector indication message up to UIProcess.
1822 2014-03-25 Anders Carlsson <andersca@apple.com>
1824 Add more properties to WKWindowFeatures
1825 https://bugs.webkit.org/show_bug.cgi?id=130738
1827 Reviewed by Tim Horton.
1829 * UIProcess/API/Cocoa/WKWindowFeatures.h:
1830 * UIProcess/API/Cocoa/WKWindowFeatures.mm:
1831 (-[WKWindowFeatures _initWithWindowFeatures:WebCore::]):
1832 (-[WKWindowFeatures menuBarVisibility]):
1833 (-[WKWindowFeatures statusBarVisibility]):
1834 (-[WKWindowFeatures toolbarsVisibility]):
1835 (-[WKWindowFeatures allowsResizing]):
1837 2014-03-25 Anders Carlsson <andersca@apple.com>
1841 * UIProcess/API/Cocoa/WKWebView.h:
1842 * UIProcess/API/Cocoa/WKWebView.mm:
1843 Make WKIBActions OS X only for now.
1845 2014-03-25 Anders Carlsson <andersca@apple.com>
1847 Begin stubbing out a WKWindowFeatures class
1848 https://bugs.webkit.org/show_bug.cgi?id=130733
1850 Reviewed by Dan Bernstein.
1852 * UIProcess/API/Cocoa/WKWindowFeatures.h: Added.
1853 * UIProcess/API/Cocoa/WKWindowFeatures.mm: Added.
1854 (-[WKWindowFeatures _initWithWindowFeatures:WebCore::]):
1855 (-[WKWindowFeatures x]):
1856 (-[WKWindowFeatures y]):
1857 (-[WKWindowFeatures width]):
1858 (-[WKWindowFeatures height]):
1859 * UIProcess/API/Cocoa/WKWindowFeaturesInternal.h: Added.
1860 * WebKit2.xcodeproj/project.pbxproj:
1862 2014-03-25 Anders Carlsson <andersca@apple.com>
1864 Add goBack: and goForward: IBActions and move stopLoading: to a new WKIBActions category on WKWebView
1865 https://bugs.webkit.org/show_bug.cgi?id=130732
1867 Reviewed by Tim Horton.
1869 * UIProcess/API/Cocoa/WKWebView.h:
1870 * UIProcess/API/Cocoa/WKWebView.mm:
1871 (-[WKWebView goBack]):
1872 (-[WKWebView goForward]):
1873 (-[WKWebView validateUserInterfaceItem:]):
1874 (-[WKWebView goBack:]):
1875 (-[WKWebView goForward:]):
1876 (-[WKWebView stopLoading:]):
1878 2014-03-25 Martin Robinson <mrobinson@igalia.com>
1880 [GTK] Remove the autotools build
1881 https://bugs.webkit.org/show_bug.cgi?id=130717
1883 Reviewed by Anders Carlsson.
1885 * GNUmakefile.am: Removed.
1886 * WebKit2Prefix.h: Removed references to the autotools configure file.
1889 2014-03-25 Michał Pakuła vel Rutka <m.pakula@samsung.com>
1891 [EFL][WK2] Add NETWORK_PROCESS build option
1892 https://bugs.webkit.org/show_bug.cgi?id=130131
1894 Reviewed by Gyuyoung Kim.
1896 * PlatformEfl.cmake: Add file needed to build with NETWORK_PROCESS enabled.
1898 2014-03-24 Michał Pakuła vel Rutka <m.pakula@samsung.com>
1900 [EFL][WK2] Add an API to set process model
1901 https://bugs.webkit.org/show_bug.cgi?id=130133
1903 Reviewed by Gyuyoung Kim.
1905 Implement an API to set and get process model in ewk_context.
1906 By default process model enum value is set to EWK_PROCESS_MODEL_SHARED_SECONDARY
1907 which keeps current behaviour. Setting EWK_PROCESS_MODEL_MULTIPLE_SECONDARY
1908 will make each web view use separate web process, also enables network process.
1910 * UIProcess/API/efl/ewk_context.cpp:
1912 (EwkContext::setProcessModel):
1913 (toEwkProcessModel):
1914 (EwkContext::processModel):
1915 (ewk_context_process_model_set):
1916 (ewk_context_process_model_get):
1917 * UIProcess/API/efl/ewk_context.h:
1918 * UIProcess/API/efl/ewk_context_private.h:
1919 * UIProcess/API/efl/tests/test_ewk2_context.cpp:
1922 2014-03-24 Chris Fleizach <cfleizach@apple.com>
1924 AX: hit-testing doesn't always work correctly with WK2
1925 https://bugs.webkit.org/show_bug.cgi?id=130706
1927 Reviewed by Simon Fraser.
1929 Accessibility code was trying to do screenToRootView itself, and in
1930 some cases with embedded WK2 views that did not work.
1932 * WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm:
1933 (-[WKAccessibilityWebPageObject accessibilityHitTest:]):
1935 2014-03-24 Benjamin Poulain <bpoulain@apple.com>
1937 [WK2] SpinLock are not initialized by default, ViewUpdateDispatcher is missing an initializer
1938 https://bugs.webkit.org/show_bug.cgi?id=130705
1940 Reviewed by Simon Fraser.
1942 * WebProcess/WebPage/ViewUpdateDispatcher.cpp:
1943 (WebKit::ViewUpdateDispatcher::ViewUpdateDispatcher):
1945 2014-03-24 Enrica Casucci <enrica@apple.com>
1947 [iOS WebKit2] Dictation support.
1948 https://bugs.webkit.org/show_bug.cgi?id=130622
1949 <rdar://problem/15337316>
1951 Reviewed by Benjamin Poulain.
1953 Adding support for dictation on iOS. There are two main types of interactions
1954 with the dictation system:
1955 - initial request for context, which consists in retrieving the selected text
1956 and 5 words before the selection and 5 words after, if available.
1957 - insertion of recognized chunks of text, providing the text
1960 * UIProcess/AutoCorrectionCallback.h:
1961 (WebKit::DictationContextCallback::create):
1962 (WebKit::DictationContextCallback::~DictationContextCallback):
1963 (WebKit::DictationContextCallback::performCallbackWithReturnValue):
1964 (WebKit::DictationContextCallback::invalidate):
1965 (WebKit::DictationContextCallback::DictationContextCallback):
1966 * UIProcess/WebPageProxy.h:
1967 * UIProcess/WebPageProxy.messages.in:
1968 * UIProcess/ios/WKContentViewInteraction.h:
1969 * UIProcess/ios/WKContentViewInteraction.mm:
1970 (-[WKContentView replaceDictatedText:withText:]):
1971 (-[WKContentView requestDictationContext:]):
1972 * UIProcess/ios/WebPageProxyIOS.mm:
1973 (WebKit::WebPageProxy::dictationContextCallback):
1974 (WebKit::WebPageProxy::replaceDictatedText):
1975 (WebKit::WebPageProxy::requestDictationContext):
1976 * WebProcess/WebPage/WebPage.h:
1977 * WebProcess/WebPage/WebPage.messages.in:
1978 * WebProcess/WebPage/ios/WebPageIOS.mm:
1979 (WebKit::WebPage::requestDictationContext):
1980 (WebKit::WebPage::replaceDictatedText):
1982 2014-03-24 Andy Estes <aestes@apple.com>
1984 Yet another iOS build fix, for the 32-bit build this time.
1986 * Shared/Downloads/ios/DownloadIOS.mm:
1987 (WebKit::setUpDownloadClient):
1989 2014-03-24 Tim Horton <timothy_horton@apple.com>
1991 REGRESSION (r165872): Double-applying device scale to snapshots
1992 https://bugs.webkit.org/show_bug.cgi?id=130697
1993 <rdar://problem/16396629>
1995 Reviewed by Simon Fraser.
1997 * WebProcess/WebPage/WebPage.cpp:
1998 (WebKit::WebPage::scaledSnapshotWithOptions):
1999 Drive-by, make scaledSnapshotWithOptions respect SnapshotOptionsExcludeDeviceScaleFactor.
2001 (WebKit::WebPage::snapshotAtSize):
2002 Divide the device scale out of the scale factor
2004 * WebProcess/WebPage/WebPage.h:
2005 Rename the scale argument to scaledSnapshotWithOptions to clarify
2006 that it is an additional scale on top of the device scale.
2008 2014-03-24 Brent Fulgham <bfulgham@apple.com>
2010 Activate WebVTT Tests Once Merging is Complete
2011 https://bugs.webkit.org/show_bug.cgi?id=130420
2013 Reviewed by Eric Carlson.
2015 * Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)
2017 2014-03-24 Andy Estes <aestes@apple.com>
2021 * Shared/Downloads/ios/DownloadIOS.mm:
2022 (WebKit::setUpDownloadClient):
2023 * UIProcess/Cocoa/DownloadClient.mm:
2025 2014-03-24 Mark Rowe <mrowe@apple.com>
2027 Build fix after r166186.
2029 * UIProcess/Cocoa/DownloadClient.mm:
2031 2014-03-24 Benjamin Poulain <bpoulain@apple.com>
2033 [WK2] Make updates on ViewUpdateDispatcher less heavy
2034 https://bugs.webkit.org/show_bug.cgi?id=130626
2036 Reviewed by Darin Adler.
2038 * WebProcess/WebPage/ViewUpdateDispatcher.cpp:
2039 (WebKit::ViewUpdateDispatcher::visibleContentRectUpdate):
2040 (WebKit::ViewUpdateDispatcher::dispatchVisibleContentRectUpdate):
2041 * WebProcess/WebPage/ViewUpdateDispatcher.h:
2043 2014-03-24 Benjamin Poulain <bpoulain@apple.com>
2045 [iOS][WK2] Micro-optimize view state updates on the UIProcess side
2046 https://bugs.webkit.org/show_bug.cgi?id=130631
2048 Reviewed by Darin Adler.
2050 * UIProcess/API/Cocoa/WKWebView.mm:
2052 [UIScrollView zoomScale] is not fast enough for -[WKWebView _updateVisibleContentRects]. Since we know what the zoom view is,
2053 make a fast version hardcoding that.
2055 (-[WKWebView _updateScrollViewBackground]):
2056 (-[WKWebView _zoomToPoint:WebCore::atScale:]):
2057 (-[WKWebView _scrollToRect:WebCore::origin:WebCore::minimumScrollDistance:]):
2058 (-[WKWebView _zoomToRect:WebCore::withOrigin:WebCore::fitEntireRect:minimumScale:maximumScale:minimumScrollDistance:]):
2059 (-[WKWebView _updateVisibleContentRects]):
2060 * UIProcess/ios/WKContentView.mm:
2061 (fixedPositionRectFromExposedRect):
2062 (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
2064 2014-03-24 Dean Jackson <dino@apple.com>
2066 Remove WebGL asset entitlement
2067 https://bugs.webkit.org/show_bug.cgi?id=130685
2069 Reviewed by Simon Fraser.
2071 No longer necessary on iOS.
2073 * Configurations/WebContent-iOS.entitlements:
2075 2014-03-24 Andy Estes <aestes@apple.com>
2077 [iOS] Download support by CFURLDownloadRef under USE(CFNETWORK).
2078 https://bugs.webkit.org/show_bug.cgi?id=129322
2080 Reviewed by Anders Carlsson.
2082 Based on an original patch by Yongjun Zhang <yongjun_zhang@apple.com>.
2084 * Shared/Cocoa/APIObject.mm:
2085 (API::Object::newObject):
2086 * Shared/Downloads/ios/DownloadIOS.mm:
2087 (WebKit::dispatchOnMainThread):
2088 (WebKit::toDownload):
2089 (WebKit::setUpDownloadClient):
2090 (WebKit::Download::startWithHandle):
2091 * UIProcess/API/APIDownloadClient.h:
2092 (API::DownloadClient::~DownloadClient):
2093 * UIProcess/API/C/WKContext.cpp:
2094 (WKContextSetDownloadClient):
2095 * UIProcess/API/Cocoa/WKProcessPool.mm:
2096 (-[WKProcessPool _downloadDelegate]):
2097 (-[WKProcessPool _setDownloadDelegate:]):
2098 * UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
2099 * UIProcess/API/Cocoa/_WKDownload.h: Added.
2100 * UIProcess/API/Cocoa/_WKDownload.mm: Added.
2102 (WebKit::createAPIDownloadClient):
2103 (-[_WKDownload dealloc]):
2104 (-[_WKDownload API::]):
2105 * UIProcess/API/Cocoa/_WKDownloadDelegate.h: Added.
2106 * UIProcess/API/Cocoa/_WKDownloadInternal.h: Added.
2107 * UIProcess/Cocoa/DownloadClient.h: Added.
2108 * UIProcess/Cocoa/DownloadClient.mm: Added.
2109 * WebKit2.xcodeproj/project.pbxproj:
2111 2014-03-24 Dániel Bátyai <dbatyai.u-szeged@partner.samsung.com>
2113 [EFL][WK2] Buildfix after r166159.
2115 Reviewed by Csaba Osztrogonác.
2117 * UIProcess/API/efl/ewk_settings.cpp:
2118 (ewk_settings_file_access_from_file_urls_allowed_set):
2119 (ewk_settings_file_access_from_file_urls_allowed_get):
2121 2014-03-24 Jinwoo Song <jinwoo7.song@samsung.com>
2123 [EFL][WK2] Use C API inside ewk_settings
2124 https://bugs.webkit.org/show_bug.cgi?id=107820
2126 Reviewed by Gyuyoung Kim.
2128 Use C API inside ewk_settings instead of accessing directly
2129 internal C++ classes, to avoid violating API layering.
2131 Original-author: Christophe Dumez <ch.dumez@sisa.samsung.com>
2133 * UIProcess/API/efl/EwkView.cpp:
2135 * UIProcess/API/efl/ewk_settings.cpp:
2136 (ewk_settings_fullscreen_enabled_set):
2137 (ewk_settings_fullscreen_enabled_get):
2138 (ewk_settings_javascript_enabled_set):
2139 (ewk_settings_javascript_enabled_get):
2140 (ewk_settings_loads_images_automatically_set):
2141 (ewk_settings_loads_images_automatically_get):
2142 (ewk_settings_developer_extras_enabled_set):
2143 (ewk_settings_developer_extras_enabled_get):
2144 (ewk_settings_file_access_from_file_urls_allowed_set):
2145 (ewk_settings_file_access_from_file_urls_allowed_get):
2146 (ewk_settings_frame_flattening_enabled_set):
2147 (ewk_settings_frame_flattening_enabled_get):
2148 (ewk_settings_dns_prefetching_enabled_set):
2149 (ewk_settings_dns_prefetching_enabled_get):
2150 (ewk_settings_encoding_detector_enabled_set):
2151 (ewk_settings_encoding_detector_enabled_get):
2152 (ewk_settings_preferred_minimum_contents_width_set):
2153 (ewk_settings_preferred_minimum_contents_width_get):
2154 (ewk_settings_offline_web_application_cache_enabled_set):
2155 (ewk_settings_offline_web_application_cache_enabled_get):
2156 (ewk_settings_scripts_can_open_windows_set):
2157 (ewk_settings_scripts_can_open_windows_get):
2158 (ewk_settings_local_storage_enabled_set):
2159 (ewk_settings_local_storage_enabled_get):
2160 (ewk_settings_plugins_enabled_set):
2161 (ewk_settings_plugins_enabled_get):
2162 (ewk_settings_default_font_size_set):
2163 (ewk_settings_default_font_size_get):
2164 (ewk_settings_private_browsing_enabled_set):
2165 (ewk_settings_private_browsing_enabled_get):
2166 (ewk_settings_text_autosizing_enabled_set):
2167 (ewk_settings_text_autosizing_enabled_get):
2168 (ewk_settings_spatial_navigation_enabled_set):
2169 (ewk_settings_spatial_navigation_enabled_get):
2170 (EwkSettings::setDefaultTextEncodingName):
2171 * UIProcess/API/efl/ewk_settings_private.h:
2172 (EwkSettings::EwkSettings):
2173 (EwkSettings::preferences):
2175 2014-03-24 Zan Dobersek <zdobersek@igalia.com>
2177 [GTK][WK2] Guard NetscapePluginModule methods used in PluginInfoCache that are specific to X11 architecture
2178 https://bugs.webkit.org/show_bug.cgi?id=130663
2180 Reviewed by Carlos Garcia Campos.
2182 The two used methods are specific to the X11 plugin architecture and are not declared when building for a
2183 Wayland-only configuration. Guarding them prevents build failures, but does not ensure proper functionality
2184 which isn't a problem anyway since there's no support yet for Netscape plugins on Wayland.
2186 * UIProcess/Plugins/gtk/PluginInfoCache.cpp:
2187 (WebKit::PluginInfoCache::getPluginInfo): Guard NetscapePluginModule::parseMIMEDescription with PLUGIN_ARCHITECTURE(X11).
2188 (WebKit::PluginInfoCache::updatePluginInfo): Ditto for NetscapePluginModule::buildMIMEDescription.
2190 2014-03-24 Ryuan Choi <ryuan.choi@samsung.com>
2192 [EFL][WK2] Convert some more OwnPtr/PassOwnPtr to std::unique_ptr
2193 https://bugs.webkit.org/show_bug.cgi?id=130662
2195 Reviewed by Gyuyoung Kim.
2197 Replace uses of PassOwnPtr/OwnPtr with std::unique_ptr in remained WebKit2/Efl specific code.
2199 * UIProcess/API/efl/EwkView.h:
2200 * UIProcess/API/efl/ewk_cookie_manager.cpp:
2201 * UIProcess/API/efl/ewk_database_manager.cpp:
2202 (getDatabaseOriginsCallback):
2203 * UIProcess/API/efl/ewk_error_private.h:
2204 * UIProcess/efl/DownloadManagerEfl.cpp:
2205 (WebKit::DownloadManagerEfl::didFail):
2206 * UIProcess/efl/InputMethodContextEfl.h:
2207 (WebKit::InputMethodContextEfl::create):
2208 * UIProcess/efl/PageLoadClientEfl.cpp:
2209 (WebKit::PageLoadClientEfl::didFailLoadWithErrorForFrame):
2210 (WebKit::PageLoadClientEfl::didFailProvisionalLoadWithErrorForFrame):
2212 2014-03-23 Hyowon Kim <hw1008.kim@samsung.com>
2214 Move all EFL typedefs into EflTypedefs.h.
2215 https://bugs.webkit.org/show_bug.cgi?id=130511
2217 Reviewed by Gyuyoung Kim.
2219 * Shared/API/c/efl/WKArrayEfl.h: Remove EFL typedefs.
2220 * UIProcess/API/efl/EwkView.h: Ditto.
2222 2014-03-23 Jinwoo Song <jinwoo7.song@samsung.com>
2224 [WK2] Refine WebKit2 BatteryStatus code
2225 https://bugs.webkit.org/show_bug.cgi?id=130573
2227 Reviewed by Anders Carlsson.
2230 - Return PassRef instead of PassRefPtr in create methods
2231 - Use auto instead of iterator
2233 * UIProcess/WebBatteryManagerProxy.cpp:
2234 (WebKit::WebBatteryManagerProxy::create):
2235 * UIProcess/WebBatteryManagerProxy.h:
2236 * UIProcess/efl/BatteryProvider.cpp:
2237 (BatteryProvider::create):
2238 * UIProcess/efl/BatteryProvider.h:
2239 * WebProcess/Battery/WebBatteryManager.cpp:
2240 (WebKit::WebBatteryManager::didChangeBatteryStatus):
2241 (WebKit::WebBatteryManager::updateBatteryStatus):
2243 2014-03-23 Sam Weinig <sam@webkit.org>
2245 Simplify the HTMLConverter interface (Part 2)
2246 https://bugs.webkit.org/show_bug.cgi?id=130654
2248 Reviewed by Darin Adler.
2250 * WebProcess/WebPage/WebPage.h:
2251 * WebProcess/WebPage/ios/WebPageIOS.mm:
2252 (WebKit::WebPage::performDictionaryLookupForRange):
2253 * WebProcess/WebPage/mac/WebPageMac.mm:
2254 (WebKit::WebPage::getAttributedSubstringFromRange):
2255 (WebKit::WebPage::attributedSubstringForCharacterRangeAsync):
2256 (WebKit::WebPage::performDictionaryLookupAtLocation):
2257 (WebKit::WebPage::performDictionaryLookupForSelection):
2258 (WebKit::WebPage::performDictionaryLookupForRange):
2260 2014-03-23 David Kilzer <ddkilzer@apple.com>
2262 WebKit::resistanceForDelta() truncates 'scaleDistance' to integer value using abs()
2263 <http://webkit.org/b/130651>
2265 Reviewed by Darin Adler.
2267 Fixes the following build failure with trunk clang:
2269 WebKit2/UIProcess/mac/ViewGestureControllerMac.mm:112:28: error: using integer absolute value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]
2270 double scaleDistance = abs(limit - currentScale);
2272 WebKit2/UIProcess/mac/ViewGestureControllerMac.mm:112:28: note: use function 'fabs' instead
2273 double scaleDistance = abs(limit - currentScale);
2277 * UIProcess/mac/ViewGestureControllerMac.mm:
2278 (WebKit::resistanceForDelta): Use fabs() instead of abs().
2280 2014-03-23 Simon Fraser <simon.fraser@apple.com>
2282 Clean up #includes by geometry classes
2283 https://bugs.webkit.org/show_bug.cgi?id=130645
2285 Reviewed by Andreas Kling.
2287 Pulling in <wtf/Vector.h> and <wtf/PrintStream.h> in the simple geometry
2288 classes brings in a lot of additional headers. Fix by adding a new
2289 GeometryUtilities file so that the basic files don't need Vector,
2290 and including GeometryUtilities.h where necessary.
2292 Also forward declare PrintStream.h and only bring in the header
2293 in implementation files.
2295 * Shared/UpdateInfo.h:
2296 * UIProcess/BackingStore.h:
2297 * UIProcess/CoordinatedGraphics/PageViewportController.h:
2298 * UIProcess/FindIndicator.cpp:
2299 * UIProcess/mac/WKPrintingView.h:
2301 2014-03-23 Simon Fraser <simon.fraser@apple.com>
2303 Clean up #includes by geometry classes
2304 https://bugs.webkit.org/show_bug.cgi?id=130645
2306 Reviewed by Andreas Kling.
2308 Pulling in <wtf/Vector.h> and <wtf/PrintStream.h> in the simple geometry
2309 classes brings in a lot of additional headers. Fix by adding a new
2310 GeometryUtilities file so that the basic files don't need Vector,
2311 and including GeometryUtilities.h where necessary.
2313 Also forward declare PrintStream.h and only bring in the header
2314 in implementation files.
2316 * UIProcess/BackingStore.h:
2317 * UIProcess/FindIndicator.cpp:
2318 * UIProcess/mac/WKPrintingView.h:
2320 2014-03-22 Alexey Proskuryakov <ap@apple.com>
2322 Assertions in WebPage::rangeFromEditingRange when requested range location is NSNotFound
2323 https://bugs.webkit.org/show_bug.cgi?id=130633
2324 <rdar://problem/16397583>
2326 Reviewed by Darin Adler.
2328 * UIProcess/API/mac/WKView.mm:
2329 (-[WKView firstRectForCharacterRange:completionHandler:]):
2330 (-[WKView firstRectForCharacterRange:actualRange:]):
2331 Return NSZeroRect, like NSTextView does for any locations that are out of bounds.
2332 There is no need for a round trip to WebProcess in this case.
2334 2014-03-21 Benjamin Poulain <bpoulain@apple.com>
2336 [iOS][WK2] Reduce the tiling coverage to the current rect and 1 tile size ahead
2337 https://bugs.webkit.org/show_bug.cgi?id=130555
2339 Reviewed by Simon Fraser.
2341 * Shared/VisibleContentRectUpdateInfo.cpp:
2342 (WebKit::VisibleContentRectUpdateInfo::encode):
2343 (WebKit::VisibleContentRectUpdateInfo::decode):
2344 * Shared/VisibleContentRectUpdateInfo.h:
2345 (WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo):
2346 (WebKit::operator==):
2347 * UIProcess/ios/WKContentView.mm:
2348 (WebKit::HistoricalKinematicData::HistoricalKinematicData):
2349 (WebKit::HistoricalKinematicData::velocityForNewData):
2350 (WebKit::HistoricalKinematicData::clear):
2351 (WebKit::HistoricalKinematicData::append):
2352 (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
2353 * WebProcess/WebPage/ViewUpdateDispatcher.cpp:
2354 (WebKit::ViewUpdateDispatcher::visibleContentRectUpdate):
2355 * WebProcess/WebPage/ios/WebPageIOS.mm:
2356 (WebKit::WebPage::updateVisibleContentRects):
2358 2014-03-21 Alexey Proskuryakov <ap@apple.com>
2360 REGRESSION (r165356): Predictive Chinese input is broken
2361 https://bugs.webkit.org/show_bug.cgi?id=130619
2363 Reviewed by Enrica Casucci.
2365 * UIProcess/mac/WebPageProxyMac.mm: (WebKit::WebPageProxy::executeKeypressCommands):
2366 Like after insertText, we are no longer in an intermediate state after executeKeypressCommands.
2367 Make sure that we don't call -discardMarkedText the next time we get a non-intermediate
2368 state with closed composition.
2370 2014-03-21 Sam Weinig <sam@webkit.org>
2372 [WebKit2] Implement NetworkingContext::sourceApplicationAuditData() for WebKit2
2373 https://bugs.webkit.org/show_bug.cgi?id=130528
2375 Reviewed by Tim Horton.
2377 * Platform/IPC/Connection.h:
2378 * Platform/IPC/mac/ConnectionMac.cpp:
2379 (IPC::Connection::getAuditToken):
2380 Expose the audit data if available.
2382 * NetworkProcess/mac/RemoteNetworkingContext.mm:
2383 (WebKit::RemoteNetworkingContext::sourceApplicationAuditData):
2384 * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
2385 (WebKit::WebFrameNetworkingContext::sourceApplicationAuditData):
2386 Pass the audit data corresponding to the UIProcess.
2388 * Configurations/Network-iOS.entitlements: Copied from Configurations/WebContent-iOS.entitlements.
2389 * Configurations/NetworkProcess.xcconfig:
2390 * Configurations/NetworkService.Development.xcconfig:
2391 * Configurations/NetworkService.xcconfig:
2392 * Configurations/WebContent-iOS.entitlements:
2393 Add entitlement allowing the audit data to be used.
2395 2014-03-21 Tim Horton <timothy_horton@apple.com>
2397 Always retrieve the screen scale factor from WKSI
2398 <rdar://problem/16329679>
2400 Reviewed by Sam Weinig.
2402 * UIProcess/ios/WKContentView.mm:
2403 (-[WKContentView initWithFrame:context:WebKit::configuration:WebKit::webView:]):
2404 (-[WKContentView _updateForScreen:]):
2405 Use WKGetScreenScaleFactor/WKGetScaleFactorForScreen.
2407 2014-03-21 Yongjun Zhang <yongjun_zhang@apple.com>
2409 [Webkit2] Add APIDownloadClient for download support.
2410 https://bugs.webkit.org/show_bug.cgi?id=130484
2412 Add API::DownloadClient to WebContext and get rid of WebDownloadClient.
2414 Reviewed by Anders Carlsson.
2416 * UIProcess/API/APIDownloadClient.h: Added.
2417 (API::DownloadClient::~DownloadClient):
2418 (API::DownloadClient::didStart):
2419 (API::DownloadClient::didReceiveAuthenticationChallenge):
2420 (API::DownloadClient::didReceiveResponse):
2421 (API::DownloadClient::didReceiveData):
2422 (API::DownloadClient::shouldDecodeSourceDataOfMIMEType):
2423 (API::DownloadClient::decideDestinationWithSuggestedFilename):
2424 (API::DownloadClient::didCreateDestination):
2425 (API::DownloadClient::didFinish):
2426 (API::DownloadClient::didFail):
2427 (API::DownloadClient::didCancel):
2428 (API::DownloadClient::processDidCrash):
2429 * UIProcess/API/C/WKContext.cpp:
2430 (WKContextSetDownloadClient): Move the original WebDownloadClient methods to a local class
2431 DownloadClient and set up the downloadClient for WebContext.
2432 * UIProcess/Downloads/DownloadProxy.cpp:
2433 * UIProcess/WebContext.cpp:
2434 (WebKit::WebContext::setDownloadClient):
2435 * UIProcess/WebContext.h:
2436 (WebKit::WebContext::downloadClient):
2437 * UIProcess/WebDownloadClient.cpp: Removed.
2438 * UIProcess/WebDownloadClient.h: Removed.
2439 * WebKit2.xcodeproj/project.pbxproj:
2441 2014-03-21 Alexey Proskuryakov <ap@apple.com>
2443 ASSERTION FAILED: event == [NSApp currentEvent] hitting Command-+
2444 https://bugs.webkit.org/show_bug.cgi?id=130526
2445 <rdar://problem/16371612>
2447 This was fixed yesterday for sync code path, landing the same this for async one.
2449 * UIProcess/API/mac/WKView.mm: (-[WKView performKeyEquivalent:]):
2451 2014-03-21 Pratik Solanki <psolanki@apple.com>
2453 Add callbacks in WebKit2 Cocoa API for page load testing
2454 https://bugs.webkit.org/show_bug.cgi?id=130569
2456 Reviewed by Anders Carlsson.
2458 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInLoadDelegate.h:
2459 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
2460 (didFirstVisuallyNonEmptyLayoutForFrame):
2461 (didHandleOnloadEventsForFrame):
2462 (setUpPageLoaderClient):
2463 (willSendRequestForFrame):
2464 (didInitiateLoadForResource):
2465 (didFinishLoadForResource):
2466 (didFailLoadForResource):
2467 (setUpResourceLoadClient):
2469 2014-03-21 Ryuan Choi <ryuan.choi@samsung.com>
2471 [EFL][WK2] Remove Ewk_Error parameter from some async callbacks
2472 https://bugs.webkit.org/show_bug.cgi?id=130567
2474 Reviewed by Gyuyoung Kim.
2476 WebKit2 internally uses GenericCallbacks for several APIs such as WKKeyValueStorageManagerGetKeyValueStorageOrigins.
2477 But only few callbacks really return errors.
2479 This patch removes Ewk_Error parameters from these callbacks not to make
2480 the confusion for application developers.
2482 * UIProcess/API/efl/ewk_cookie_manager.cpp:
2483 (getAcceptPolicyCallback):
2484 (getHostnamesWithCookiesCallback):
2485 * UIProcess/API/efl/ewk_cookie_manager.h:
2486 * UIProcess/API/efl/ewk_database_manager.cpp:
2487 (getDatabaseOriginsCallback):
2488 * UIProcess/API/efl/ewk_database_manager.h:
2489 * UIProcess/API/efl/ewk_storage_manager.cpp:
2490 (getStorageOriginsCallback):
2491 * UIProcess/API/efl/ewk_storage_manager.h:
2492 * UIProcess/API/efl/tests/test_ewk2_cookie_manager.cpp:
2493 (EWK2CookieManagerTest::getAcceptPolicyCallback):
2494 (EWK2CookieManagerTest::getHostnamesWithCookiesCallback):
2495 * UIProcess/API/efl/tests/test_ewk2_database_manager.cpp:
2496 (EWK2DatabaseManagerTest::databaseOriginsCallback):
2497 * UIProcess/API/efl/tests/test_ewk2_storage_manager.cpp:
2498 (EWK2StorageManagerTest::getStorageOriginsCallback):
2500 2014-03-21 Darin Adler <darin@apple.com>
2502 Improve idiom used for string building in a few places
2503 https://bugs.webkit.org/show_bug.cgi?id=130561
2505 Reviewed by Andreas Kling.
2507 * Shared/mac/ChildProcessMac.mm:
2508 (WebKit::ChildProcess::initializeSandbox): Use a more efficient idiom for string
2511 * UIProcess/WebInspectorProxy.cpp:
2512 (WebKit::WebInspectorProxy::createInspectorPage): Use a StringBuilder.
2514 2014-03-20 Hyowon Kim <hw1008.kim@samsung.com>
2516 Move to using std::unique_ptr for EFL objects.
2517 https://bugs.webkit.org/show_bug.cgi?id=129853
2519 Reviewed by Gyuyoung Kim.
2521 EflUniquePtr is a template alias of std::unique_ptr
2522 with a custom deleter for each Efl Objects, which is motivated by GUniquePtr.
2523 This patch replaces uses of OwnPtr and PassOwnPtr for Efl objects with EflUniquePtr.
2525 * Platform/Module.h:
2526 * Platform/efl/ModuleEfl.cpp:
2527 (WebKit::Module::load):
2528 * UIProcess/API/efl/EwkView.cpp:
2530 * UIProcess/API/efl/EwkView.h:
2531 * UIProcess/efl/InputMethodContextEfl.cpp:
2532 (WebKit::InputMethodContextEfl::InputMethodContextEfl):
2533 (WebKit::InputMethodContextEfl::createIMFContext):
2534 * UIProcess/efl/InputMethodContextEfl.h:
2535 (WebKit::InputMethodContextEfl::create):
2537 2014-03-20 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2539 [EFL][GTK] Get CMake to find Freetype2 properly
2540 https://bugs.webkit.org/show_bug.cgi?id=130150
2542 Reviewed by Martin Robinson.
2544 Newer versions of CMake are not able to find Freetype2 correctly.
2545 FindFreetype2.cmake checks for the version number in freetype.h header, since it seems that bug exists in
2546 freetype2 repo, because a completely different version number is found in freetype2.pc.
2548 * PlatformEfl.cmake:
2550 2014-03-20 Martin Robinson <mrobinson@igalia.com>
2552 [GTK] Suppress errors about using gdk_threads_enter gdk_threads_leave
2553 https://bugs.webkit.org/show_bug.cgi?id=130517
2555 Reviewed by Sergio Villar Senin.
2557 * UIProcess/API/gtk/WebKitWebView.cpp: Use GCC suppression to suppress errors about deprecations.
2558 * UIProcess/gtk/WebPopupMenuProxyGtk.cpp: Ditto.
2560 2014-03-20 Ryuan Choi <ryuan.choi@samsung.com>
2562 [EFL][WK2] tests of test_ewk2_cookie_manager are flaky
2563 https://bugs.webkit.org/show_bug.cgi?id=130498
2565 Reviewed by Gyuyoung Kim.
2567 Loaded web page before calling getAcceptPolicy() to guarantee that webprocess
2568 or networkprocess was launched and registered WebCookieManager.
2570 * UIProcess/API/efl/tests/test_ewk2_cookie_manager.cpp:
2573 2014-03-20 Commit Queue <commit-queue@webkit.org>
2575 Unreviewed, rolling out r165985.
2576 https://bugs.webkit.org/show_bug.cgi?id=130551
2578 broke page loading on all cocoa platforms (Requested by
2579 thorton on #webkit).
2583 "[WebKit2] Implement
2584 NetworkingContext::sourceApplicationAuditData() for WebKit2"
2585 https://bugs.webkit.org/show_bug.cgi?id=130528
2586 http://trac.webkit.org/changeset/165985
2588 2014-03-20 Alexey Proskuryakov <ap@apple.com>
2590 Fix a long-standing typo that's now breaking USE(ASYNC_NSTEXTINPUTCLIENT) build.
2592 Rubber-stamped by Tim Horton.
2594 * UIProcess/mac/WebPageProxyMac.mm: (WebKit::WebPageProxy::cancelComposition):
2595 Use a correct type for reply (it's really the same type, but ConfirmComposition
2596 is behind an ifdef, and not available).
2598 2014-03-20 Enrica Casucci <enrica@apple.com>
2600 [iOS WebKit2] typing and deleting text lags behind the caret movement on google.com.
2601 https://bugs.webkit.org/show_bug.cgi?id=130544
2602 <rdar://problem/16380296>
2604 Reviewed by Tim Horton.
2606 On iOS the selection is drawn in the UIProcess. If the WebProcess is
2607 processing multiple requests within the same runloop, the caret could be
2608 updated in the UIProcess before the WebProcess has had a chance to paint.
2609 This change synchronizes the selection drawing with the tile update.
2611 * UIProcess/WebPageProxy.h:
2612 * UIProcess/ios/WKContentView.mm:
2613 (-[WKContentView _didCommitLayerTree:WebKit::]):
2614 * UIProcess/ios/WKContentViewInteraction.h:
2615 * UIProcess/ios/WKContentViewInteraction.mm:
2616 (-[WKContentView _selectionChanged]):
2617 (-[WKContentView _updateChangedSelection]):
2618 * WebProcess/WebPage/WebPage.cpp:
2619 (WebKit::WebPage::didChangeSelection):
2621 2014-03-20 Alexey Proskuryakov <ap@apple.com>
2623 Generalize WebInspector check in maybeInitializeSandboxExtensionHandle().
2624 https://bugs.webkit.org/show_bug.cgi?id=130079
2625 <rdar://problem/16286683>
2627 Reviewed by Anders Carlsson.
2629 * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):
2630 Perform an early return for all paths that don't need a sandbox extension due to
2631 access being assumed, not only for WebInspector pages.
2633 * UIProcess/WebProcessProxy.cpp:
2634 (WebKit::WebProcessProxy::hasAssumedReadAccessToURL):
2635 (WebKit::WebProcessProxy::checkURLReceivedFromWebProcess):
2636 * UIProcess/WebProcessProxy.h:
2637 Factored out m_localPathsWithAssumedReadAccess iteration to a public function.
2639 2014-03-20 Csaba Osztrogonác <ossy@webkit.org>
2641 Unreviewed buildfix after r165983 for non Cocoa platforms.
2643 * UIProcess/API/C/WKAPICast.h:
2644 * UIProcess/API/C/WKPreferences.cpp:
2645 * UIProcess/efl/WebInspectorProxyEfl.cpp:
2647 2014-03-20 Beth Dakin <bdakin@apple.com>
2649 Implement contentInset for Mac WebKit2
2650 https://bugs.webkit.org/show_bug.cgi?id=130273
2652 Reviewed by Simon Fraser.
2654 This patch adds WKView API for setting a topContentInset(). All of this work gets
2655 that number plumbed down to WebCore.
2657 * Shared/WebPageCreationParameters.cpp:
2658 (WebKit::WebPageCreationParameters::encode):
2659 (WebKit::WebPageCreationParameters::decode):
2660 * Shared/WebPageCreationParameters.h:
2661 * UIProcess/API/Cocoa/WKViewPrivate.h:
2662 * UIProcess/API/Cocoa/WKWebView.mm:
2663 (-[WKWebView _setTopContentInset:]):
2664 (-[WKWebView _topContentInset]):
2665 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2666 * UIProcess/API/mac/WKView.mm:
2667 (-[WKView _setTopContentInset:]):
2668 (-[WKView _topContentInset]):
2669 * UIProcess/WebPageProxy.cpp:
2670 (WebKit::WebPageProxy::WebPageProxy):
2671 (WebKit::WebPageProxy::setTopContentInset):
2672 (WebKit::WebPageProxy::creationParameters):
2673 * UIProcess/WebPageProxy.h:
2674 (WebKit::WebPageProxy::topContentInset):
2675 * WebProcess/WebPage/WebPage.cpp:
2676 (WebKit::WebPage::WebPage):
2677 (WebKit::WebPage::setTopContentInset):
2678 * WebProcess/WebPage/WebPage.h:
2679 * WebProcess/WebPage/WebPage.messages.in:
2681 2014-03-20 Anders Carlsson <andersca@apple.com>
2685 * UIProcess/API/Cocoa/WKProcessPoolConfiguration.mm:
2687 2014-03-20 Anders Carlsson <andersca@apple.com>
2689 Make WKProcessPoolConfiguration SPI
2690 https://bugs.webkit.org/show_bug.cgi?id=130537
2692 Reviewed by Tim Horton.
2694 * UIProcess/API/Cocoa/WKProcessPool.h:
2695 * UIProcess/API/Cocoa/WKProcessPool.mm:
2696 (-[WKProcessPool init]):
2697 (-[WKProcessPool dealloc]):
2698 (-[WKProcessPool description]):
2699 (-[WKProcessPool _configuration]):
2700 (-[WKProcessPool API::]):
2701 (-[WKProcessPool _initWithConfiguration:]):
2702 * UIProcess/API/Cocoa/WKProcessPoolConfiguration.h:
2703 * UIProcess/API/Cocoa/WKProcessPoolConfiguration.mm:
2704 (-[WKProcessPoolConfiguration _injectedBundleURL]):
2705 (-[WKProcessPoolConfiguration _setInjectedBundleURL:]):
2706 * UIProcess/API/Cocoa/WKProcessPoolConfigurationPrivate.h:
2707 * UIProcess/API/Cocoa/WKProcessPoolInternal.h:
2708 * UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
2709 * UIProcess/API/Cocoa/WKProcessPoolToBeRemoved.mm: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKProcessPoolPrivate.h.
2710 (-[WKProcessPool initWithConfiguration:]):
2711 (-[WKProcessPool configuration]):
2712 * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKProcessPoolConfigurationPrivate.h.
2713 * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKProcessPoolConfiguration.mm.
2714 (-[_WKProcessPoolConfiguration injectedBundleURL]):
2715 (-[_WKProcessPoolConfiguration setInjectedBundleURL:]):
2716 (-[_WKProcessPoolConfiguration description]):
2717 (-[_WKProcessPoolConfiguration copyWithZone:]):
2718 * WebKit2.xcodeproj/project.pbxproj:
2720 2014-03-20 Tim Horton <timothy_horton@apple.com>
2722 Add WebCore::IOSurface wrapper
2723 https://bugs.webkit.org/show_bug.cgi?id=130529
2725 Reviewed by Simon Fraser.
2727 * Shared/mac/RemoteLayerBackingStore.h:
2728 * Shared/mac/RemoteLayerBackingStore.mm:
2729 (RemoteLayerBackingStore::encode):
2730 (RemoteLayerBackingStore::decode):
2731 (RemoteLayerBackingStore::display):
2732 (RemoteLayerBackingStore::applyBackingStoreToLayer):
2733 * UIProcess/ios/ViewGestureControllerIOS.mm:
2734 (WebKit::ViewGestureController::beginSwipeGesture):
2735 (WebKit::ViewGestureController::removeSwipeSnapshot):
2736 * UIProcess/mac/ViewGestureController.h:
2737 * UIProcess/mac/ViewGestureControllerMac.mm:
2738 (WebKit::ViewGestureController::beginSwipeGesture):
2739 (WebKit::ViewGestureController::removeSwipeSnapshot):
2740 * UIProcess/mac/ViewSnapshotStore.h:
2741 * UIProcess/mac/ViewSnapshotStore.mm:
2742 (WebKit::createIOSurfaceFromImage):
2743 (WebKit::ViewSnapshotStore::recordSnapshot):
2744 Adopt WebCore::IOSurface.
2746 2014-03-20 Alexey Proskuryakov <ap@apple.com>
2748 Update iOS input method code to use new cross-platform async functions
2749 https://bugs.webkit.org/show_bug.cgi?id=130530
2751 Reviewed by Enrica Casucci.
2753 Merge identical iOS and cross-platform functions.
2755 Also tightened up ifdefs, and removed stub iOS implementations of sync methods,
2756 which hopefully won't be ever needed. The only tricky case is sync cancelComposition,
2757 will I'll investigate separately.
2759 * UIProcess/WebPageProxy.h:
2760 * UIProcess/ios/WKContentViewInteraction.mm:
2761 (-[WKContentView setMarkedText:selectedRange:]):
2762 (-[WKContentView unmarkText]):
2763 (-[WKContentView insertText:]):
2764 * UIProcess/ios/WebPageProxyIOS.mm:
2765 (WebKit::WebPageProxy::cancelComposition):
2766 * UIProcess/mac/WebPageProxyMac.mm:
2767 (WebKit::WebPageProxy::cancelComposition):
2768 (WebKit::WebPageProxy::insertDictatedTextAsync):
2769 (WebKit::WebPageProxy::attributedSubstringForCharacterRangeAsync):
2770 (WebKit::WebPageProxy::attributedStringForCharacterRangeCallback):
2771 * WebProcess/WebPage/WebPage.h:
2772 * WebProcess/WebPage/WebPage.messages.in:
2773 * WebProcess/WebPage/ios/WebPageIOS.mm:
2774 * WebProcess/WebPage/mac/WebPageMac.mm:
2775 (WebKit::WebPage::cancelComposition):
2776 (WebKit::WebPage::insertDictatedTextAsync):
2777 (WebKit::WebPage::attributedSubstringForCharacterRangeAsync):
2779 2014-03-20 Alexey Proskuryakov <ap@apple.com>
2781 ASSERTION FAILED: event == [NSApp currentEvent] hitting Command-+
2782 https://bugs.webkit.org/show_bug.cgi?id=130526
2783 <rdar://problem/16371612>
2785 Reviewed by Anders Carlsson.
2787 * UIProcess/API/mac/WKView.mm: (-[WKView performKeyEquivalent:]): Cut custom
2788 processing short whenever we are redispatching an event, not just when the event
2789 we are handling is the one being redispatched. There shouldn't be any other unrelated
2790 events here, just the one being redispatched and synthetic ones generated from it by AppKit.
2792 2014-03-20 Anders Carlsson <andersca@apple.com>
2796 Rename WKPreferencesPrivate.h to WKPreferencesRefPrivate.h.
2798 * UIProcess/API/C/WKPreferencesRefPrivate.h: Renamed from Source/WebKit2/UIProcess/API/C/WKPreferencesPrivate.h.
2799 * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
2800 * WebKit2.xcodeproj/project.pbxproj:
2802 2014-03-20 Gavin Barraclough <barraclough@apple.com>
2804 Merge AtomicString, Identifier
2805 https://bugs.webkit.org/show_bug.cgi?id=128624
2807 Unreviewed build fix following r165982.
2809 * WebProcess/Plugins/Netscape/NPJSObject.cpp:
2812 2014-03-20 Sam Weinig <sam@webkit.org>
2814 [WebKit2] Implement NetworkingContext::sourceApplicationAuditData() for WebKit2
2815 https://bugs.webkit.org/show_bug.cgi?id=130528
2817 Reviewed by Anders Carlsson.
2819 * Platform/IPC/Connection.h:
2820 * Platform/IPC/mac/ConnectionMac.cpp:
2821 (IPC::Connection::getAuditToken):
2822 Expose the audit data if available.
2824 * NetworkProcess/mac/RemoteNetworkingContext.mm:
2825 (WebKit::RemoteNetworkingContext::sourceApplicationAuditData):
2826 * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
2827 (WebKit::WebFrameNetworkingContext::sourceApplicationAuditData):
2828 Pass the audit data corresponding to the UIProcess.
2830 2014-03-20 Sam Weinig <sam@webkit.org>
2832 [Cocoa] Expose preference to enable telephone number detection
2833 https://bugs.webkit.org/show_bug.cgi?id=130524
2835 Reviewed by Anders Carlsson.
2837 * UIProcess/API/Cocoa/WKPreferences.mm:
2838 (-[WKPreferences _telephoneNumberDetectionIsEnabled]):
2839 (-[WKPreferences _setTelephoneNumberDetectionIsEnabled:]):
2840 * UIProcess/API/Cocoa/WKPreferencesInternal.h:
2841 * UIProcess/API/Cocoa/WKPreferencesPrivate.h: Added.
2842 * WebKit2.xcodeproj/project.pbxproj:
2844 2014-03-19 Alexey Proskuryakov <ap@apple.com>
2846 [Mac] Support asynchronous NSTextInputClient
2847 https://bugs.webkit.org/show_bug.cgi?id=130479
2849 Reviewed by Anders Carlsson.
2851 The implementation is currently disabled, pending lower level support.
2852 Most of the code is not under compile time guard however, to facilitate cross-platform
2853 reuse, or at least under a PLATFORM(COCOA) guard to share the code with iOS.
2855 * UIProcess/API/mac/WKView.mm: Added a compile time branch for USE(ASYNC_NSTEXTINPUTCLIENT).
2856 We still implement sync NSTextInputClient here, in order to get assertions when
2857 its methods are unexpectedly called.
2858 The new code first sends an event to input method asynchronously, handling any callbacks
2859 that may arrive. During this time, we no longer care about WKViewInterpretKeyEventsParameters
2860 at all. Once done, we interpret key bindings synchronously, collecting them into
2863 * UIProcess/API/mac/WKViewInternal.h: We no longer expose _interpretKeyEvent outside
2866 * UIProcess/WebPageProxy.cpp:
2867 * UIProcess/WebPageProxy.h:
2868 Added async calls and callbacks. Removed unnecessary and slightly harmful .get() when moving
2869 a callback pointer into map. Moved insertDictatedText() and getAttributedSubstringFromRange()
2870 from PLATFORM(COCOA) to PLATFORM(MAC), because they are unused and unimplemented on
2871 iOS, and unlikely to be needed any time soon. Changed USE(APPKIT) to PLATFORM(MAC),
2872 because that's more accurate in this case (nothing depends on AppKit, it's just code
2873 that we only need on Mac).
2875 * UIProcess/WebPageProxy.messages.in: Added messages for new async IM responses.
2877 * UIProcess/ios/WebPageProxyIOS.mm: Removed insertDictatedText() and getAttributedSubstringFromRange().
2879 * UIProcess/mac/WebPageProxyMac.mm:
2880 (WebKit::WebPageProxy::insertDictatedTextAsync):
2881 (WebKit::WebPageProxy::attributedSubstringForCharacterRangeAsync):
2882 (WebKit::WebPageProxy::attributedStringForCharacterRangeCallback):
2883 Added async calls and callbacks that are Mac only.
2885 * WebProcess/WebPage/WebPage.cpp:
2886 * WebProcess/WebPage/WebPage.h:
2887 * WebProcess/WebPage/mac/WebPageMac.mm:
2888 Added async implementations (which are essentially the same as sync ones, sadly).
2890 * WebProcess/WebPage/WebPage.messages.in: Added async messages, moved some messages
2891 under PLATFORM(MAC).
2893 * WebProcess/WebPage/ios/WebPageIOS.mm: More of deleting functions that are Mac only,
2894 and cannot be easily implemented in WebPage.cpp with shared code.
2896 2014-03-20 Martin Robinson <mrobinson@igalia.com>
2898 Remove remaining GTK+ unused parameter warnings from WebKit2
2899 https://bugs.webkit.org/show_bug.cgi?id=130518
2901 Reviewed by Sergio Villar Senin.
2903 Fix almost all unused parameter warnings in the WebKit2GTK+ build.
2905 2014-03-20 Commit Queue <commit-queue@webkit.org>
2907 Unreviewed, rolling out r165962.
2908 https://bugs.webkit.org/show_bug.cgi?id=130512
2910 It broke the build (Requested by Ossy on #webkit).
2914 "[EFL][GTK] Get CMake to find Freetype2 properly"
2915 https://bugs.webkit.org/show_bug.cgi?id=130150
2916 http://trac.webkit.org/changeset/165962
2918 2014-03-20 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2920 [EFL][GTK] Get CMake to find Freetype2 properly
2921 https://bugs.webkit.org/show_bug.cgi?id=130150
2923 Reviewed by Csaba Osztrogonác.
2925 Newer versions of CMake are not able to find Freetype2 correctly.
2926 FindFreetype2.cmake checks for the version number in freetype.h header, since it seems that bug exists in
2927 freetype2 repo, because a completely different version number is found in freetype2.pc.
2929 * PlatformEfl.cmake:
2931 2014-03-20 Ryuan Choi <ryuan.choi@samsung.com>
2933 [EFL][WK2] test_ewk2_application_cache_manager is flaky
2934 https://bugs.webkit.org/show_bug.cgi?id=130501
2936 Reviewed by Gyuyoung Kim.
2938 * UIProcess/API/efl/tests/test_ewk2_application_cache_manager.cpp:
2939 (timerCallback): Return ECORE_CALLBACK_CANCEL to clear the timer.
2941 2014-03-19 Tim Horton <timothy_horton@apple.com>
2943 Address late review comment and style nit after r165934.
2945 * UIProcess/ios/ViewGestureControllerIOS.mm:
2946 (WebKit::ViewGestureController::beginSwipeGesture):
2948 2014-03-19 Tim Horton <timothy_horton@apple.com>
2950 [iOS][WebKit2] Back-forward swipe doesn't always complete with fingers down
2951 https://bugs.webkit.org/show_bug.cgi?id=130489
2952 <rdar://problem/16027007>
2954 Reviewed by Simon Fraser.
2956 * UIProcess/ios/ViewGestureControllerIOS.mm:
2957 (WebKit::ViewGestureController::beginSwipeGesture):
2958 In order to have fingers-down swipe completion work correctly, we need
2959 to give UIKit an empty interactive update block.
2961 2014-03-19 Anders Carlsson <andersca@apple.com>
2963 Get rid of two IPC::Connection functions by folding them into lambdas
2964 https://bugs.webkit.org/show_bug.cgi?id=130482
2966 Reviewed by Tim Horton.
2968 * Platform/IPC/Connection.cpp:
2969 (IPC::Connection::addWorkQueueMessageReceiver):
2970 (IPC::Connection::removeWorkQueueMessageReceiver):
2971 * Platform/IPC/Connection.h:
2973 2014-03-19 Simon Fraser <simon.fraser@apple.com>
2975 Expose text and page zoom in WK2 SPI, and hook them up in MiniBrowser
2976 https://bugs.webkit.org/show_bug.cgi?id=130476
2978 Reviewed by Anders Carlsson.
2980 Expose page and text zoom as SPI.
2982 * UIProcess/API/Cocoa/WKWebView.mm:
2983 (-[WKWebView _supportsTextZoom]):
2984 (-[WKWebView _textZoomFactor]):
2985 (-[WKWebView _setTextZoomFactor:]):
2986 (-[WKWebView _pageZoomFactor]):
2987 (-[WKWebView _setPageZoomFactor:]):
2988 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2990 2014-03-19 Benjamin Poulain <bpoulain@apple.com>
2992 [iOS][WK2] Reduce the extended background's opacity when WKContentView is smaller than its WKWebView
2993 https://bugs.webkit.org/show_bug.cgi?id=130436
2995 Reviewed by Beth Dakin.
2997 * UIProcess/API/Cocoa/WKWebView.mm:
2998 (-[WKWebView _updateScrollViewBackground]):
3000 2014-03-19 Benjamin Poulain <bpoulain@apple.com>
3002 [iOS][WebKit2] <rdar://problem/16330387> Do not use the keyboard rect for computing the general unobscuredRect, only use it for centering
3003 https://bugs.webkit.org/show_bug.cgi?id=130382
3005 Reviewed by Simon Fraser.
3007 Always accumulating the keyboard rect out of the exposedRect caused some issues (see <rdar://problem/16330387>).
3008 This patch split the rect in two: unobscured rect for WebCore, and unobscuredContentRectIncludingKeyboard for centering
3009 UI Elements in view.
3011 * UIProcess/API/Cocoa/WKWebView.mm:
3012 (-[WKWebView _zoomToRect:WebCore::atScale:origin:WebCore::]):
3013 (-[WKWebView _scrollToRect:WebCore::origin:WebCore::minimumScrollDistance:]):
3014 (-[WKWebView _zoomToRect:WebCore::withOrigin:WebCore::fitEntireRect:minimumScale:maximumScale:minimumScrollDistance:]):
3015 (-[WKWebView _contentRectForUserInteraction]):
3016 (-[WKWebView _updateVisibleContentRects]):
3018 2014-03-19 Anders Carlsson <andersca@apple.com>
3020 Get rid of WKProcessClass
3021 https://bugs.webkit.org/show_bug.cgi?id=130478
3023 Reviewed by Dan Bernstein.
3025 * UIProcess/API/Cocoa/WKProcessClass.h: Removed.
3026 * UIProcess/API/Cocoa/WKProcessClass.mm: Removed.
3027 * UIProcess/API/Cocoa/WKProcessClassConfiguration.h: Removed.
3028 * UIProcess/API/Cocoa/WKProcessClassConfiguration.mm: Removed.
3029 * UIProcess/API/Cocoa/WKProcessClassConfigurationPrivate.h: Removed.
3030 * UIProcess/API/Cocoa/WKProcessClassPrivate.h: Removed.
3031 * UIProcess/API/Cocoa/WKWebViewConfigurationToBeRemoved.mm: Removed.
3032 * WebKit2.xcodeproj/project.pbxproj:
3034 2014-03-19 Jer Noble <jer.noble@apple.com>
3036 [Mac][EME] Query whether decoder support exists before creating a new MediaKeys object.
3037 https://bugs.webkit.org/show_bug.cgi?id=130459
3039 Reviewed by Eric Carlson.
3041 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3042 (InitWebCoreSystemInterface): Initialize the new WCSI method.
3044 2014-03-19 Brady Eidson <beidson@apple.com>
3046 Filter out editable services from image menu for non-contenteditable images
3047 <rdar://problem/16319645> and https://bugs.webkit.org/show_bug.cgi?id=130437
3049 Reviewed by Tim Horton.
3051 * UIProcess/mac/WebContextMenuProxyMac.h:
3052 * UIProcess/mac/WebContextMenuProxyMac.mm:
3053 (-[WKSharingServicePickerDelegate setIncludeEditorServices:]):
3054 (-[WKSharingServicePickerDelegate sharingServicePicker:sharingServicesForItems:mask:proposedSharingServices:]):
3055 Filter out editing services based on the includeEditorServices flag.
3056 (WebKit::WebContextMenuProxyMac::setupImageServicesMenu):
3057 (WebKit::WebContextMenuProxyMac::populate):
3059 2014-03-19 Yongjun Zhang <yongjun_zhang@apple.com>
3061 [iOS] WebKit2 Quicklook.
3062 https://bugs.webkit.org/show_bug.cgi?id=130360
3064 For WebKit2 resource loads, if we detect a quicklook content that QLConverter is able to
3065 convert, handle the response data to QLConverter and use its delegate WKWebResourceQuickLookDelegate
3066 to rounte the converted results (HTML) back into WebCore. Thie similiar logic has been in place
3069 Reviewed by Tim Horton.
3071 * WebKit2.xcodeproj/project.pbxproj: Add WebResourceLoaderIOS.mm to the project.
3072 * WebProcess/Network/WebResourceLoadScheduler.cpp:
3073 * WebProcess/ios/WebResourceLoaderIOS.mm: Added.
3074 (-[WKWebResourceQuickLookDelegate initWithWebResourceLoader:WebKit::]): WKWebResourceQuickLookDelegate holds
3075 the original WebResourceLoader so that we could send converted result to WebCore.
3076 (-[WKWebResourceQuickLookDelegate connection:didReceiveDataArray:]):
3077 (-[WKWebResourceQuickLookDelegate connection:didReceiveData:lengthReceived:]):
3078 (-[WKWebResourceQuickLookDelegate connectionDidFinishLoading:]):
3079 (-[WKWebResourceQuickLookDelegate connection:didFailWithError:]):
3080 (-[WKWebResourceQuickLookDelegate clearHandle]):
3081 (WebKit::WebResourceLoader::setUpQuickLookHandleIfNeeded):
3083 2014-03-19 Tim Horton <timothy_horton@apple.com>
3085 WebKit2 View Gestures: Swipe gesture can track vertical movement instead of horizontal movement
3086 https://bugs.webkit.org/show_bug.cgi?id=130441
3087 <rdar://problem/16337279>
3089 Reviewed by Simon Fraser.
3091 * UIProcess/mac/ViewGestureControllerMac.mm:
3092 (WebKit::scrollEventCanBecomeSwipe):
3093 Factor logic that determines if a scroll event can become a swipe
3094 out into scrollEventCanBecomeSwipe.
3095 Use <= instead of < when comparing the axes, because we don't want
3096 to start a swipe on a completely diagonal scroll either (because AppKit
3097 can start tracking a vertical swipe in that case).
3099 (WebKit::ViewGestureController::handleScrollWheelEvent):
3100 (WebKit::ViewGestureController::wheelEventWasNotHandledByWebCore):
3101 Make use of scrollEventCanBecomeSwipe.
3103 2014-03-18 Anders Carlsson <andersca@apple.com>
3105 Add new functionality that will be required by the history item decoding
3106 https://bugs.webkit.org/show_bug.cgi?id=130433
3108 Reviewed by Sam Weinig.
3110 * Shared/cf/KeyedDecoder.cpp:
3111 (WebKit::KeyedDecoder::decodeUInt32):
3112 (WebKit::KeyedDecoder::decodeInt32):
3113 (WebKit::KeyedDecoder::decodeFloat):
3114 * Shared/cf/KeyedDecoder.h:
3116 2014-03-19 Tim Horton <timothy_horton@apple.com>
3118 [iOS] WebPDFViewPlaceholder divides-by-zero with an empty document
3119 https://bugs.webkit.org/show_bug.cgi?id=130444
3120 <rdar://problem/15580682>
3122 Reviewed by Sam Weinig.
3124 * UIProcess/ios/WKPDFView.mm:
3125 (-[WKPDFView web_setContentProviderData:]):
3126 Don't make UIPDFPageViews for null pages.
3128 2014-03-18 Tim Horton <timothy_horton@apple.com>
3130 [iOS][WebKit2] Provide generic software-snapshotting API
3131 https://bugs.webkit.org/show_bug.cgi?id=130385
3132 <rdar://problem/16005957>
3134 Reviewed by Sam Weinig.
3136 * UIProcess/API/Cocoa/WKWebView.mm:
3137 (-[WKWebView _didCommitLayerTree:WebKit::]):
3138 (-[WKWebView _snapshotRect:intoImageOfWidth:completionHandler:]):
3139 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3140 * UIProcess/API/Cocoa/_WKThumbnailView.mm:
3141 (-[_WKThumbnailView initWithFrame:fromWKView:]):
3142 (-[_WKThumbnailView _requestSnapshotIfNeeded]):
3143 * UIProcess/WebPageProxy.cpp:
3144 (WebKit::WebPageProxy::internalShowContextMenu):
3145 * UIProcess/WebPageProxy.h:
3146 * WebProcess/WebPage/WebPage.cpp:
3147 (WebKit::WebPage::takeSnapshot):
3148 (WebKit::WebPage::scaledSnapshotWithOptions):
3149 (WebKit::WebPage::snapshotAtSize):
3150 * WebProcess/WebPage/WebPage.h:
3151 * WebProcess/WebPage/WebPage.messages.in:
3152 Rename TakeThumbnailSnapshot message to TakeSnapshot.
3154 Fill the snapshot image with the FrameView's background color, to avoid
3155 half-pixel alpha around the edges.
3157 Factor snapshotAtSize out of scaledSnapshotWithOptions.
3159 Don't apply both the custom and device scale factor to the base CTM,
3160 only the device scale factor. Custom scale factor should only be
3161 applied to the user CTM.
3163 * Shared/ImageOptions.h:
3164 Add a snapshot option, RespectDrawingAreaTransform, that maps
3165 the rect through the drawing area's root layer transform.
3166 Use this in place of the thumbnail-specific code in TakeThumbnailSnapshot.
3167 Add a snapshot option, ExcludeDeviceScaleFactor, which means that
3168 snapshotting will not factor the device scale in (useful for drawing
3169 to a bitmap at an exact requested size).
3171 2014-03-18 Samuel White <samuel_white@apple.com>
3173 AX: Not able to use arrow keys to read text with VoiceOver before selection is set someplace (anyplace).
3174 https://bugs.webkit.org/show_bug.cgi?id=130250
3176 Reviewed by Chris Fleizach.
3178 Added ability to toggle enhanced accessibility on and off to support tests that require it.
3180 * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
3181 (WKAccessibilityEnableEnhancedAccessibility):
3182 (WKAccessibilityEnhancedAccessibilityEnabled):
3183 * WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
3185 2014-03-18 Ryuan Choi <ryuan.choi@samsung.com>
3187 [EFL][WK2] Rename async APIs for better consistency with EFL
3188 https://bugs.webkit.org/show_bug.cgi?id=130319
3190 Reviewed by Gyuyoung Kim.
3192 There are inconsistency with async keyword in several ewebkit2 APIs.
3193 This patch rename them to {module/feature}_async_{verb} for better consistency with EFL.
3194 In addition, added Async keyword into their callback name.
3196 * UIProcess/API/efl/ewk_application_cache_manager.cpp:
3197 (EwkApplicationCacheOriginsAsyncData::EwkApplicationCacheOriginsAsyncData):
3198 (getApplicationCacheOriginsCallback):
3199 (ewk_application_cache_manager_origins_async_get):
3200 * UIProcess/API/efl/ewk_application_cache_manager.h:
3201 * UIProcess/API/efl/ewk_cookie_manager.cpp:
3202 (EwkCookiePolicyAsyncData::EwkCookiePolicyAsyncData):
3203 (getAcceptPolicyCallback):
3204 (ewk_cookie_manager_accept_policy_async_get):
3205 (EwkCookieHostnamesAsyncData::EwkCookieHostnamesAsyncData):
3206 (getHostnamesWithCookiesCallback):
3207 (ewk_cookie_manager_hostnames_with_cookies_async_get):
3208 * UIProcess/API/efl/ewk_cookie_manager.h:
3209 * UIProcess/API/efl/ewk_database_manager.cpp:
3210 (EwkDatabaseOriginsAsyncData::EwkDatabaseOriginsAsyncData):
3211 (getDatabaseOriginsCallback):
3212 (ewk_database_manager_origins_async_get):
3213 * UIProcess/API/efl/ewk_database_manager.h:
3214 * UIProcess/API/efl/ewk_storage_manager.cpp:
3215 (EwkStorageOriginsAsyncData::EwkStorageOriginsAsyncData):
3216 (getStorageOriginsCallback):
3217 (ewk_storage_manager_origins_async_get):
3218 * UIProcess/API/efl/ewk_storage_manager.h:
3219 * UIProcess/API/efl/tests/test_ewk2_application_cache_manager.cpp:
3221 * UIProcess/API/efl/tests/test_ewk2_cookie_manager.cpp:
3222 (EWK2CookieManagerTest::getAcceptPolicy):
3223 (EWK2CookieManagerTest::getHostnamesWithCookies):
3224 * UIProcess/API/efl/tests/test_ewk2_database_manager.cpp:
3225 (EWK2DatabaseManagerTest::timerCallback):
3227 * UIProcess/API/efl/tests/test_ewk2_storage_manager.cpp:
3228 (EWK2StorageManagerTest::timerCallback):
3231 2014-03-18 Tim Horton <timothy_horton@apple.com>
3233 [iOS][WebKit2] Mark layer contents as being opaque if they are
3234 https://bugs.webkit.org/show_bug.cgi?id=130427
3235 <rdar://problem/15540434>
3237 Reviewed by Simon Fraser.
3239 * Shared/mac/RemoteLayerBackingStore.h:
3240 (WebKit::RemoteLayerBackingStore::isOpaque):
3241 * Shared/mac/RemoteLayerBackingStore.mm:
3242 (RemoteLayerBackingStore::RemoteLayerBackingStore):
3243 (RemoteLayerBackingStore::ensureBackingStore):
3244 (RemoteLayerBackingStore::encode):
3245 (RemoteLayerBackingStore::decode):
3246 (RemoteLayerBackingStore::display):
3247 (RemoteLayerBackingStore::applyBackingStoreToLayer):
3248 Move the code to set a RemoteLayerBackingStore as a CALayer's contents
3249 from RemoteLayerTreePropertyApplier to RemoteLayerBackingStore (mostly
3250 as a way to keep the USE(IOSURFACE) #ifs in one place).
3251 Remove the surface() getter, because it's no longer needed, and make
3252 image() private as it can be now (and rename it to createImageForFrontBuffer
3253 for clarity's sake).
3255 Add an isOpaque argument to ensureBackingStore, encode/decode it, and
3256 add a getter. If isOpaque is true when applying backing store to the
3257 CALayer on the UI process side, set CALayer.contentsOpaque to let CA know.
3259 Make opaque bitmaps if not using accelerated drawing. For the IOSurface
3260 case, we can't make opaque IOSurfaces, but telling CA that we have filled
3261 the whole bitmap still enables similar optimizations.
3263 * Shared/mac/RemoteLayerTreePropertyApplier.mm:
3264 (WebKit::applyPropertiesToLayer):
3265 Reset contentsOpaque if the layer loses its backing store.
3267 * Shared/mac/RemoteLayerTreeTransaction.mm:
3268 (WebKit::RemoteLayerTreeTextStream::operator<<):
3269 (WebKit::dumpChangedLayers):
3270 Add a bit more logging about RemoteLayerBackingStore's opaqueness
3271 and acceleratedness.
3273 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
3274 (PlatformCALayerRemote::updateBackingStore):
3275 (PlatformCALayerRemote::setOpaque):
3276 Invalidate the RemoteLayerBackingStore if layer opaqueness changes.
3278 2014-03-18 Brady Eidson <beidson@apple.com>
3280 Make image controls menu work in WK2
3281 <rdar://problem/16294412> and https://bugs.webkit.org/show_bug.cgi?id=130424
3283 Reviewed by Tim Horton.
3285 * Platform/SharedMemory.h:
3286 * Platform/mac/SharedMemoryMac.cpp:
3287 (WebKit::SharedMemory::Handle::~Handle):
3288 (WebKit::SharedMemory::Handle::clear):
3290 * Platform/unix/SharedMemoryUnix.cpp:
3291 (WebKit::SharedMemory::Handle::~Handle):
3292 (WebKit::SharedMemory::Handle::clear):
3294 * Shared/ContextMenuContextData.cpp:
3295 (WebKit::ContextMenuContextData::ContextMenuContextData):
3296 (WebKit::ContextMenuContextData::operator=):
3297 (WebKit::ContextMenuContextData::encode):
3298 (WebKit::ContextMenuContextData::decode):
3299 * Shared/ContextMenuContextData.h:
3300 (WebKit::ContextMenuContextData::controlledImageHandle):
3302 * Shared/ShareableBitmap.cpp:
3303 (WebKit::ShareableBitmap::Handle::clear):
3304 * Shared/ShareableBitmap.h:
3305 * UIProcess/WebContextMenuProxy.h:
3307 * UIProcess/WebPageProxy.cpp:
3308 (WebKit::WebPageProxy::internalShowContextMenu):
3309 (WebKit::WebPageProxy::replaceControlledImage):
3310 * UIProcess/WebPageProxy.h:
3312 * UIProcess/efl/WebContextMenuProxyEfl.cpp:
3313 (WebKit::WebContextMenuProxyEfl::showContextMenu):
3314 * UIProcess/efl/WebContextMenuProxyEfl.h:
3316 * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
3317 (WebKit::WebContextMenuProxyGtk::showContextMenu):
3318 * UIProcess/gtk/WebContextMenuProxyGtk.h:
3320 Add a sharing service context menu that lives side-by-side with the normal one:
3321 * UIProcess/mac/WebContextMenuProxyMac.h:
3322 * UIProcess/mac/WebContextMenuProxyMac.mm:
3323 (+[WKSharingServicePickerDelegate sharedSharingServicePickerDelegate]):
3324 (-[WKSharingServicePickerDelegate setMenuProxy:WebKit::]):
3325 (-[WKSharingServicePickerDelegate setPicker:]):
3326 (-[WKSharingServicePickerDelegate sharingServicePicker:delegateForSharingService:]):
3327 (-[WKSharingServicePickerDelegate sharingService:willShareItems:]):
3328 (-[WKSharingServicePickerDelegate sharingService:didShareItems:]):
3329 (-[WKSharingServicePickerDelegate sharingService:sourceFrameOnScreenForShareItem:]):
3330 (-[WKSharingServicePickerDelegate sharingService:transitionImageForShareItem:contentRect:]):
3331 (-[WKSharingServicePickerDelegate sharingService:sourceWindowForShareItems:sharingContentScope:]):
3332 (WebKit::WebContextMenuProxyMac::contextMenuItemSelected):
3333 (WebKit::WebContextMenuProxyMac::setupImageServicesMenu):
3334 (WebKit::WebContextMenuProxyMac::clearImageServicesMenu):
3335 (WebKit::WebContextMenuProxyMac::populate):
3336 (WebKit::WebContextMenuProxyMac::showContextMenu):
3337 (WebKit::WebContextMenuProxyMac::window):
3338 (WebKit::WebContextMenuProxyMac::replaceControlledImage):
3340 * WebProcess/WebPage/WebContextMenu.cpp:
3341 (WebKit::WebContextMenu::show):
3342 (WebKit::WebContextMenu::replaceControlledImage):
3343 * WebProcess/WebPage/WebContextMenu.h:
3345 Teach the WebProcess how to accept the replaced image.
3346 * WebProcess/WebPage/WebPage.cpp:
3347 (WebKit::WebPage::replaceControlledImage):
3348 * WebProcess/WebPage/WebPage.h:
3349 * WebProcess/WebPage/WebPage.messages.in:
3351 2014-03-18 Anders Carlsson <andersca@apple.com>
3353 Begin cleaning up KeyedDecoder and KeyedEncoder
3354 https://bugs.webkit.org/show_bug.cgi?id=130431
3356 Reviewed by Tim Horton.
3358 * Shared/cf/KeyedDecoder.cpp:
3359 (WebKit::KeyedDecoder::KeyedDecoder):
3360 If we can't parse the property list data, just add an empty dictionary to the stack.
3362 (WebKit::KeyedDecoder::decodeBool):
3363 Remove unneeded m_dictionaryStack.last() null check. m_dictionaryStack would either be empty
3364 or at least have a root element; it would never have a null element.
3366 (WebKit::KeyedDecoder::decodeDouble):
3367 Remove the same check as above and remove the CFNumberGetType checks since CFNumberGetValue will
3368 do the type conversion for us and return false if it's lossy.
3370 (WebKit::KeyedDecoder::decodeInt64):
3371 Remove the m_dictionaryStack.last() check.
3373 (WebKit::KeyedDecoder::decodeUInt32):
3376 (WebKit::KeyedDecoder::decodeString):
3379 (WebKit::KeyedDecoder::beginObject):
3382 (WebKit::KeyedDecoder::beginArray):
3385 (WebKit::KeyedDecoder::beginArrayElement):
3388 * Shared/cf/KeyedDecoder.h:
3389 Sort functions to be in the same logical order as the base class.
3391 * Shared/cf/KeyedEncoder.cpp:
3392 (WebKit::KeyedEncoder::finishEncoding):
3393 Don't check for a non-null CFErrorRef here (which we incidentally never released on error). Instead,
3394 just null check the returned CFDataRef object.
3396 2014-03-18 Joseph Pecoraro <pecoraro@apple.com>
3398 Unreviewed typo build fix for r165846.
3400 * Shared/WebPageCreationParameters.cpp:
3401 (WebKit::WebPageCreationParameters::decode):
3403 2014-03-18 Joseph Pecoraro <pecoraro@apple.com>
3405 WebKit2 SPI to disable remote inspection on a WKWebView / WKPage
3406 https://bugs.webkit.org/show_bug.cgi?id=130371
3408 Reviewed by Dan Bernstein.
3410 * Shared/WebPageCreationParameters.h:
3411 * Shared/WebPageCreationParameters.cpp:
3412 (WebKit::WebPageCreationParameters::encode):
3413 (WebKit::WebPageCreationParameters::decode):
3414 Add allowsRemoteInspection bool.
3416 * UIProcess/API/C/WKPagePrivate.h:
3417 * UIProcess/API/C/WKPage.cpp:
3418 (WKPageGetAllowsRemoteInspection):
3419 (WKPageSetAllowsRemoteInspection):
3420 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3421 * UIProcess/API/Cocoa/WKWebView.mm:
3422 (-[WKWebView _allowsRemoteInspection]):
3423 (-[WKWebView _setAllowsRemoteInspection:]):
3424 Getter and setter for allowing remote inspection state.
3426 * UIProcess/WebPageProxy.h:
3427 (WebKit::WebPageProxy::allowsRemoteInspection):
3428 * UIProcess/WebPageProxy.cpp:
3429 (WebKit::WebPageProxy::WebPageProxy):
3430 (WebKit::WebPageProxy::setAllowsRemoteInspection):
3431 (WebKit::WebPageProxy::creationParameters):
3432 Cached allows remote inspection state, with getter and setter.
3434 * WebProcess/WebPage/WebPage.h:
3435 * WebProcess/WebPage/WebPage.messages.in:
3436 * WebProcess/WebPage/WebPage.cpp:
3437 (WebKit::WebPage::setAllowsRemoteInspection):
3438 When setting, call into WebCore to adjust the Page's setting.
3440 2014-03-18 Anders Carlsson <andersca@apple.com>
3442 REGRESSION: Visited link coloring seems to be completely broken in tip of tree
3443 https://bugs.webkit.org/show_bug.cgi?id=130419
3444 <rdar://problem/16337850>
3446 Reviewed by Dan Bernstein.
3448 Make sure to send any queued up messages before calling connectionWillOpen so we'll ensure
3449 FIFO ordering if any messages are sent from within connectionWillOpen.
3451 * Shared/ChildProcessProxy.cpp:
3452 (WebKit::ChildProcessProxy::didFinishLaunching):
3454 2014-03-18 Joseph Pecoraro <pecoraro@apple.com>
3456 WebPageCreationParameters colorSpace should be MAC not COCOA
3457 https://bugs.webkit.org/show_bug.cgi?id=130414
3459 Reviewed by Dan Bernstein.
3461 The colorSpace param was only set and used on Mac, not iOS.
3463 * Shared/WebPageCreationParameters.h:
3464 * Shared/WebPageCreationParameters.cpp:
3465 (WebKit::WebPageCreationParameters::encode):
3466 (WebKit::WebPageCreationParameters::decode):
3468 2014-03-18 Simon Fraser <simon.fraser@apple.com>
3470 Dan says that options should be unsigned, and enums should be signed.
3472 Reviewed by Dan Bernstein.
3474 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3477 2014-03-17 Alexey Proskuryakov <ap@apple.com>
3479 [WK2] Pass ranges over IPC in a cross-platform manner
3480 https://bugs.webkit.org/show_bug.cgi?id=130376
3482 Reviewed by Anders Carlsson.
3484 Added an EditingRange class for IPC, which automatically converts to and from
3485 NSRanges, knowing the difference between notFound and NSNotFound.
3487 Manually applied the same fix to characterIndexForPoint.
3489 * Scripts/webkit2/messages.py:
3491 * Shared/EditingRange.h: Added.
3492 (WebKit::EditingRange::EditingRange):
3493 (WebKit::EditingRange::isValid):
3494 (WebKit::EditingRange::operator NSRange):
3495 * UIProcess/API/mac/WKView.mm:
3496 (-[WKView insertText:replacementRange:]):
3497 (-[WKView selectedRange]):
3498 (-[WKView hasMarkedText]):
3499 (-[WKView setMarkedText:selectedRange:replacementRange:]):
3500 (-[WKView markedRange]):
3501 (-[WKView attributedSubstringForProposedRange:actualRange:]):
3502 (-[WKView characterIndexForPoint:]):
3503 (-[WKView firstRectForCharacterRange:actualRange:]):
3504 * UIProcess/WebPageProxy.h:
3505 * UIProcess/ios/WKContentViewInteraction.mm:
3506 (-[WKContentView setMarkedText:selectedRange:]):
3507 (-[WKContentView insertText:]):
3508 * UIProcess/ios/WebPageProxyIOS.mm:
3509 (WebKit::WebPageProxy::setComposition):
3510 (WebKit::WebPageProxy::insertText):
3511 (WebKit::WebPageProxy::insertDictatedText):
3512 (WebKit::WebPageProxy::getMarkedRange):
3513 (WebKit::WebPageProxy::getSelectedRange):
3514 (WebKit::WebPageProxy::getAttributedSubstringFromRange):
3515 (WebKit::WebPageProxy::firstRectForCharacterRange):
3516 * UIProcess/mac/WebPageProxyMac.mm:
3517 (WebKit::WebPageProxy::setComposition):
3518 (WebKit::WebPageProxy::insertText):
3519 (WebKit::WebPageProxy::insertDictatedText):
3520 (WebKit::WebPageProxy::getMarkedRange):
3521 (WebKit::WebPageProxy::getSelectedRange):
3522 (WebKit::WebPageProxy::getAttributedSubstringFromRange):
3523 (WebKit::WebPageProxy::firstRectForCharacterRange):
3524 * WebKit2.xcodeproj/project.pbxproj:
3525 * WebProcess/WebPage/WebPage.cpp:
3526 (WebKit::WebPage::rangeFromEditingRange):
3527 * WebProcess/WebPage/WebPage.h:
3528 * WebProcess/WebPage/WebPage.messages.in:
3529 * WebProcess/WebPage/ios/WebPageIOS.mm:
3530 (WebKit::WebPage::setComposition):
3531 (WebKit::WebPage::insertText):
3532 (WebKit::WebPage::insertDictatedText):
3533 (WebKit::WebPage::getMarkedRange):
3534 (WebKit::WebPage::getSelectedRange):
3535 (WebKit::WebPage::getAttributedSubstringFromRange):
3536 (WebKit::WebPage::firstRectForCharacterRange):
3537 * WebProcess/WebPage/mac/WebPageMac.mm:
3538 (WebKit::WebPage::setComposition):
3539 (WebKit::WebPage::insertText):
3540 (WebKit::WebPage::insertDictatedText):
3541 (WebKit::WebPage::getMarkedRange):
3542 (WebKit::WebPage::getSelectedRange):
3543 (WebKit::WebPage::getAttributedSubstringFromRange):
3544 (WebKit::WebPage::characterIndexForPoint):
3545 (WebKit::WebPage::firstRectForCharacterRange):
3547 2014-03-17 Filip Pizlo <fpizlo@apple.com>
3551 Rubber stamped by Dan Bernstein.
3553 * Configurations/FeatureDefines.xcconfig:
3555 2014-03-17 Simon Fraser <simon.fraser@apple.com>
3557 Renable pagination mode in WK2 MiniBrowser
3558 https://bugs.webkit.org/show_bug.cgi?id=130374
3560 Reviewed by Anders Carlsson.
3562 Add SPI for pagination mode.
3564 * UIProcess/API/Cocoa/WKWebView.mm:
3565 (-[WKWebView _paginationMode]):
3566 (-[WKWebView _setPaginationMode:]):
3567 (-[WKWebView _paginationBehavesLikeColumns]):
3568 (-[WKWebView _setPaginationBehavesLikeColumns:]):
3569 (-[WKWebView _pageLength]):
3570 (-[WKWebView _setPageLength:]):
3571 (-[WKWebView _gapBetweenPages]):
3572 (-[WKWebView _setGapBetweenPages:]):
3573 (-[WKWebView _pageCount]):
3574 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3577 2014-03-18 Ryuan Choi <ryuan.choi@samsung.com>
3579 [CMAKE][WK2]Move CoordinatedGraphics related files out of WebKit2/CMakeLists.txt
3580 https://bugs.webkit.org/show_bug.cgi?id=130390
3582 Reviewed by Martin Robinson.
3584 Now, only EFL port use CoordinatedGraphics among CMake based ports.
3587 * PlatformEfl.cmake:
3588 * PlatformGTK.cmake: Removed CoordinatedGraphics related files.
3590 2014-03-18 Carlos Garcia Campos <cgarcia@igalia.com>
3592 [GTK] Race condition when the socket event source is cancelled
3593 https://bugs.webkit.org/show_bug.cgi?id=130395
3595 Reviewed by Martin Robinson.
3597 In some cases when the socket event source is cancelled the socket
3598 event source callback is called with the condition of the previous
3599 poll instead of 0. This can happen sometimes when the source is
3600 cancelled from the socket event source callback. Once the socket
3601 event source is cancelled, it's dispatched by glib without
3602 polling, so the condition is never reset again and the callback is
3603 called again and again with the previous condition. When the
3604 condition is G_IO_IN, the source is re-scheduled entering into an
3605 infinite loop. We should always check if the source has been
3606 cancelled at the beginning of the callback to destroy the source
3607 instead of relying on the condition being 0.
3609 * Platform/gtk/WorkQueueGtk.cpp:
3610 (WorkQueue::SocketEventSource::isCancelled):
3611 (WorkQueue::SocketEventSource::eventCallback):
3613 2014-03-18 Csaba Osztrogonác <ossy@webkit.org>
3615 [GTK] URTFB after r165789. Stub function added.
3617 * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3618 (WebKit::InjectedBundle::setBundleParameter):
3620 2014-03-17 Jaehun Lim <ljaehun.lim@samsung.com>
3622 Unreviewed, EFL build fix after r165789
3624 * WebProcess/InjectedBundle/efl/InjectedBundleEfl.cpp:
3625 (WebKit::InjectedBundle::setBundleParameter): Implemented.
3627 2014-03-17 Jae Hyun Park <jaepark@webkit.org>
3629 [GTK] Build fix for debug build
3633 finalizedListItem was actually used in ASSERT. So, use ASSERT_UNUSED
3636 * UIProcess/API/gtk/WebKitBackForwardListItem.cpp:
3637 (webkitBackForwardListItemFinalized):
3639 2014-03-17 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
3641 [WK2] Getting rid of compilation warnings
3642 https://bugs.webkit.org/show_bug.cgi?id=130348
3644 Reviewed by Benjamin Poulain.
3646 * UIProcess/API/APIHistoryClient.h:
3647 (API::HistoryClient::didPerformClientRedirect):
3648 (API::HistoryClient::didPerformServerRedirect):
3649 (API::HistoryClient::didUpdateHistoryTitle):
3650 * UIProcess/API/APILoaderClient.h:
3651 (API::LoaderClient::didStartProvisionalLoadForFrame):
3652 (API::LoaderClient::didReceiveServerRedirectForProvisionalLoadForFrame):
3653 (API::LoaderClient::didFailProvisionalLoadWithErrorForFrame):
3654 (API::LoaderClient::didCommitLoadForFrame):
3655 (API::LoaderClient::didFinishLoadForFrame):
3656 (API::LoaderClient::didFailLoadWithErrorForFrame):
3657 (API::LoaderClient::didChangeBackForwardList):
3658 * UIProcess/API/APIPolicyClient.h:
3659 (API::PolicyClient::decidePolicyForNavigationAction):
3660 (API::PolicyClient::decidePolicyForNewWindowAction):
3661 (API::PolicyClient::decidePolicyForResponse):
3662 (API::PolicyClient::unableToImplementPolicy):
3663 * UIProcess/API/APIUIClient.h:
3664 (API::UIClient::exceededDatabaseQuota):
3665 (API::UIClient::saveDataToFileInDownloadsFolder):
3666 * UIProcess/API/C/WKPage.cpp:
3667 (WKPageSetPageLoaderClient):
3668 * UIProcess/APISession.cpp:
3670 * WebProcess/Plugins/PluginView.cpp:
3671 (WebKit::PluginView::viewStateDidChange):
3673 2014-03-17 Anders Carlsson <andersca@apple.com>
3675 Update the bundle parameters dictionary and send out KVO notifications
3676 https://bugs.webkit.org/show_bug.cgi?id=130379
3677 <rdar://problem/16213914>
3679 Reviewed by Dan Bernstein.
3681 * UIProcess/API/Cocoa/WKProcessPool.mm:
3682 (-[WKProcessPool _setObject:forBundleParameter:]):
3683 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
3684 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
3685 (-[WKWebProcessBundleParameters setParameter:forKey:]):
3686 * WebProcess/InjectedBundle/InjectedBundle.h:
3687 * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
3688 (WebKit::InjectedBundle::setBundleParameter):
3689 * WebProcess/WebProcess.cpp:
3690 (WebKit::WebProcess::setInjectedBundleParameter):
3691 * WebProcess/WebProcess.h:
3692 * WebProcess/WebProcess.messages.in:
3694 2014-03-17 Tim Horton <timothy_horton@apple.com>
3696 Address some style nits.
3698 * UIProcess/API/Cocoa/_WKThumbnailViewInternal.h:
3700 2014-03-17 Simon Fraser <simon.fraser@apple.com>
3702 Address some style nits.
3704 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3706 2014-03-17 Simon Fraser <simon.fraser@apple.com>
3708 Add transparent window support back into MiniBrowser
3709 https://bugs.webkit.org/show_bug.cgi?id=130363
3711 Reviewed by Anders Carlsson.
3713 Expose SPI for transparent window support.
3715 * UIProcess/API/Cocoa/WKWebView.mm:
3716 (-[WKWebView _drawsTransparentBackground]):
3717 (-[WKWebView _setDrawsTransparentBackground:]):
3718 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3720 2014-03-17 Alexey Proskuryakov <ap@apple.com>
3722 Undo some accidental Gtk changes from http://trac.webkit.org/changeset/165759
3724 * UIProcess/WebPageProxy.cpp:
3725 * WebProcess/WebPage/WebPage.messages.in:
3727 2014-03-17 Csaba Osztrogonác <ossy@webkit.org>
3729 [WK2] URTBF after r165755 for non Apple platforms, stub functions added.
3731 * WebProcess/InjectedBundle/efl/InjectedBundleEfl.cpp:
3732 (WebKit::InjectedBundle::platformInitialize):
3733 * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3734 (WebKit::InjectedBundle::platformInitialize):
3736 2014-03-17 Alexey Proskuryakov <ap@apple.com>
3738 Move convertToRange() helper to cross-platform WebPage.cpp
3739 https://bugs.webkit.org/show_bug.cgi?id=130365
3741 Reviewed by Tim Horton.
3743 Also renamed it to rangeFromEditingLocationAndLength().
3745 * WebProcess/WebPage/WebPage.cpp:
3746 (WebKit::WebPage::rangeFromEditingLocationAndLength):
3747 * WebProcess/WebPage/WebPage.h:
3748 * WebProcess/WebPage/ios/WebPageIOS.mm:
3749 (WebKit::WebPage::insertText):
3750 * WebProcess/WebPage/mac/WebPageMac.mm:
3751 (WebKit::WebPage::setComposition):
3752 (WebKit::WebPage::insertText):
3753 (WebKit::WebPage::insertDictatedText):
3754 (WebKit::WebPage::getAttributedSubstringFromRange):
3755 (WebKit::WebPage::characterIndexForPoint):
3756 (WebKit::WebPage::firstRectForCharacterRange):
3758 2014-03-17 Anders Carlsson <andersca@apple.com>
3762 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
3764 2014-03-17 Enrica Casucci <enrica@apple.com>
3766 WK2: support data detectors driven action sheet..
3767 https://bugs.webkit.org/show_bug.cgi?id=130362
3768 <rdar://problem/16319711>
3770 Reviewed by Benjamin Poulain.
3772 * UIProcess/ios/WKActionSheetAssistant.mm:
3773 (-[WKActionSheetAssistant showDataDetectorsSheet]):
3775 2014-03-17 Anders Carlsson <andersca@apple.com>
3777 Fix 32-bit OS X build.
3779 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
3780 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
3781 * WebProcess/InjectedBundle/InjectedBundle.h:
3782 * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
3783 (WebKit::InjectedBundle::platformInitialize):
3785 2014-03-17 Jae Hyun Park <jaepark@webkit.org>
3787 [GTK][CMake] Fix WebKit2 unused parameter warnings
3788 https://bugs.webkit.org/show_bug.cgi?id=130316
3790 Reviewed by Martin Robinson.
3792 * Platform/gtk/WorkQueueGtk.cpp: Fix unused parameter warnings.
3793 * UIProcess/API/gtk/PageClientImpl.cpp: Ditto.
3794 * UIProcess/API/gtk/WebKitBackForwardListItem.cpp: Ditto.
3795 * UIProcess/API/gtk/WebKitContextMenuClient.cpp: Ditto.
3796 * UIProcess/API/gtk/WebKitContextMenuItem.cpp: Ditto.
3797 * UIProcess/API/gtk/WebKitDownloadClient.cpp: Ditto.
3798 * UIProcess/API/gtk/WebKitFaviconDatabase.cpp: Ditto.
3799 * UIProcess/API/gtk/WebKitFindController.cpp: Ditto.
3800 * UIProcess/API/gtk/WebKitFormClient.cpp: Ditto.
3801 * UIProcess/API/gtk/WebKitGeolocationProvider.cpp: Ditto.
3802 * UIProcess/API/gtk/WebKitLoaderClient.cpp: Ditto.
3803 * UIProcess/API/gtk/WebKitPlugin.cpp: Ditto.
3804 * UIProcess/API/gtk/WebKitPolicyClient.cpp: Ditto.
3805 * UIProcess/API/gtk/WebKitRequestManagerClient.cpp: Ditto.
3806 * UIProcess/API/gtk/WebKitTextChecker.cpp: Ditto.
3807 * UIProcess/API/gtk/WebKitUIClient.cpp: Ditto.
3808 * UIProcess/API/gtk/WebKitURISchemeRequest.cpp: Ditto.
3809 * UIProcess/API/gtk/WebKitWebContext.cpp: Ditto.
3810 * UIProcess/API/gtk/WebKitWebInspector.cpp: Ditto.
3811 * UIProcess/API/gtk/WebKitWebView.cpp: Ditto.
3812 * UIProcess/API/gtk/WebKitWebViewBase.cpp: Ditto.
3813 * UIProcess/API/gtk/WebKitWebViewBaseAccessible.cpp: Ditto.
3814 * UIProcess/API/gtk/WebViewBaseInputMethodFilter.cpp: Ditto.
3815 * UIProcess/gtk/TextCheckerGtk.cpp: Ditto.
3816 * UIProcess/gtk/WebContextMenuProxyGtk.cpp: Ditto.
3817 * UIProcess/gtk/WebPopupMenuProxyGtk.cpp: Ditto.
3818 * WebProcess/InjectedBundle/API/gtk/WebKitFrame.cpp: Ditto.
3819 * WebProcess/InjectedBundle/API/gtk/WebKitWebExtension.cpp: Ditto.
3820 * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp: Ditto.
3821 * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp: Ditto.
3822 * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: Ditto.
3824 2014-03-17 Alexey Proskuryakov <ap@apple.com>
3826 [Mac] Standardize on start/length in text input IPC methods
3827 https://bugs.webkit.org/show_bug.cgi?id=130359
3829 Reviewed by Anders Carlsson.
3831 Some IPC methods used start/length, and others use start/end. This was confusing.
3833 While here, changed WebPageMac.mm to not use NSMakeRange where we don't need it
3834 (I want to move this code to WebPage.cpp, where it could be shared with iOS and
3835 other platforms, as it doesn't depend on Foundation much).
3837 * UIProcess/API/mac/WKView.mm:
3838 (-[WKView insertText:replacementRange:]):
3839 (-[WKView setMarkedText:selectedRange:replacementRange:]):
3840 (-[WKView attributedSubstringForProposedRange:actualRange:]):
3841 * UIProcess/WebPageProxy.cpp:
3842 (WebKit::WebPageProxy::internalShowContextMenu):
3843 * UIProcess/WebPageProxy.h:
3844 * UIProcess/ios/WebPageProxyIOS.mm:
3845 (WebKit::WebPageProxy::setComposition):
3846 (WebKit::WebPageProxy::insertText):
3847 * UIProcess/mac/WebPageProxyMac.mm:
3848 (WebKit::WebPageProxy::setComposition):
3849 (WebKit::WebPageProxy::insertText):
3850 (WebKit::WebPageProxy::insertDictatedText):
3851 (WebKit::WebPageProxy::getAttributedSubstringFromRange):
3852 * WebProcess/WebPage/WebPage.cpp:
3853 (WebKit::WebPage::setComposition):
3854 * WebProcess/WebPage/WebPage.h:
3855 * WebProcess/WebPage/WebPage.messages.in:
3856 * WebProcess/WebPage/ios/WebPageIOS.mm:
3857 (WebKit::WebPage::setComposition):
3858 (WebKit::WebPage::insertText):
3859 * WebProcess/WebPage/mac/WebPageMac.mm:
3860 (WebKit::WebPage::setComposition):
3861 (WebKit::WebPage::insertText):
3862 (WebKit::WebPage::insertDictatedText):
3863 (WebKit::WebPage::getAttributedSubstringFromRange):
3864 (WebKit::convertToRange):
3865 (WebKit::WebPage::firstRectForCharacterRange):
3867 2014-03-17 Tim Horton <timothy_horton@apple.com>
3869 Rename WKThumbnailView to _WKThumbnailView
3870 https://bugs.webkit.org/show_bug.cgi?id=130361
3872 Reviewed by Anders Carlsson.
3874 * UIProcess/API/Cocoa/_WKThumbnailView.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.h.
3875 * UIProcess/API/Cocoa/_WKThumbnailView.mm: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.mm.
3876 (-[_WKThumbnailView initWithFrame:fromWKView:]):
3877 (-[_WKThumbnailView _viewWasUnparented]):
3878 (-[_WKThumbnailView _viewWasParented]):
3879 (-[_WKThumbnailView _requestSnapshotIfNeeded]):
3880 (-[_WKThumbnailView _didTakeSnapshot:]):
3881 (-[_WKThumbnailView viewDidMoveToWindow]):
3882 (-[_WKThumbnailView setScale:]):
3883 (-[_WKThumbnailView setUsesSnapshot:]):
3884 (-[_WKThumbnailView _setThumbnailLayer:]):
3885 (-[_WKThumbnailView _thumbnailLayer]):
3886 * UIProcess/API/Cocoa/_WKThumbnailViewInternal.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailViewInternal.h.
3887 * UIProcess/API/mac/WKView.mm:
3888 (-[WKView _setThumbnailView:]):
3889 (-[WKView _thumbnailView]):
3890 (-[WKView _updateThumbnailViewLayer]):
3891 * UIProcess/API/mac/WKViewInternal.h:
3892 * UIProcess/mac/PageClientImpl.mm:
3893 * WebKit2.xcodeproj/project.pbxproj:
3895 2014-03-17 Anders Carlsson <andersca@apple.com>
3897 Add SPI for getting bundle parameters from the injected bundle
3898 https://bugs.webkit.org/show_bug.cgi?id=130355
3900 Reviewed by Dan Bernstein.
3902 * UIProcess/mac/WebContextMac.mm:
3903 (WebKit::WebContext::platformInitializeWebProcess):
3904 * WebKit2.xcodeproj/project.pbxproj:
3905 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h: Copied from Source/WebKit2/WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.h.
3906 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm: Copied from Source/WebKit2/WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.h.
3907 (-[WKWebProcessBundleParameters initWithDictionary:]):
3908 (-[WKWebProcessBundleParameters valueForKey:]):
3909 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.h:
3910 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.mm:
3911 (-[WKWebProcessPlugInController parameters]):
3912 * WebProcess/InjectedBundle/InjectedBundle.cpp:
3913 (WebKit::InjectedBundle::InjectedBundle):
3914 * WebProcess/InjectedBundle/InjectedBundle.h:
3915 (WebKit::InjectedBundle::create):
3916 * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
3917 (WebKit::InjectedBundle::bundleParameters):
3918 (WebKit::InjectedBundle::platformInitialize):
3919 * WebProcess/WebProcess.cpp:
3920 (WebKit::WebProcess::initializeWebProcess):
3922 2014-03-17 Brent Fulgham <bfulgham@apple.com>
3924 Provide preference to enable additional AVFoundation options
3925 https://bugs.webkit.org/show_bug.cgi?id=130275
3927 Reviewed by Eric Carlson.
3929 * Shared/WebPreferencesStore.h: Added new preference.
3930 * UIProcess/API/C/WKPreferences.cpp:
3931 (WKPreferencesSetEnableInheritURIQueryComponent): Added.
3932 (WKPreferencesGetEnableInheritURIQueryComponent): Added.
3933 * UIProcess/API/C/WKPreferencesPrivate.h:
3934 * WebProcess/WebPage/WebPage.cpp:
3935 (WebKit::WebPage::updatePreferences): Handle new preference.
3937 2014-03-17 Alexey Proskuryakov <ap@apple.com>
3939 [Mac] getAttributedSubstringFromRange arguments are incorrectly named
3940 https://bugs.webkit.org/show_bug.cgi?id=130349
3942 Reviewed by Tim Horton.
3944 There is a mess of start/end and start/length pairs in IPC. One day we'll fix them
3945 all, but now, let's at least name them correctly.
3949 * UIProcess/WebPageProxy.h:
3950 * UIProcess/mac/WebPageProxyMac.mm:
3951 (WebKit::WebPageProxy::getAttributedSubstringFromRange):
3952 * WebProcess/WebPage/WebPage.h:
3953 * WebProcess/WebPage/WebPage.messages.in:
3954 * WebProcess/WebPage/mac/WebPageMac.mm:
3955 (WebKit::WebPage::getAttributedSubstringFromRange):
3957 2014-03-17 Tim Horton <timothy_horton@apple.com>
3959 WKThumbnailView should support snapshots
3960 https://bugs.webkit.org/show_bug.cgi?id=130335
3961 <rdar://problem/16255139>
3963 Reviewed by Simon Fraser.
3965 Add a mode where WKThumbnailView takes a software snapshot of the web content,
3966 replacing the live layer tree with said snapshot once it returns from the
3967 web process. This may improve animation performance in cases where the
3968 layer tree would otherwise be very complex.
3970 * UIProcess/API/Cocoa/WKThumbnailView.h:
3971 Add a property, usesSnapshot, which determines whether the thumbnail view
3972 should use the live layer tree or a snapshot of the content.
3974 * UIProcess/API/Cocoa/WKThumbnailView.mm:
3975 (-[WKThumbnailView initWithFrame:fromWKView:]):
3976 (-[WKThumbnailView _viewWasUnparented]):
3977 Clear the snapshot when unparented.
3979 (-[WKThumbnailView _viewWasParented]):
3980 Take a snapshot of the web content when parented, if needed.
3982 (-[WKThumbnailView _requestSnapshotIfNeeded]):
3983 If we're using snapshots, and haven't already dispatched an async snapshot request,
3984 and don't already have a snapshot, request a snapshot from the web process.
3986 When it returns, use it as the contents of the WKThumbnailView layer, and
3987 unparent the live layer tree.
3989 (-[WKThumbnailView setScale:]):
3990 (-[WKThumbnailView setUsesSnapshot:]):
3991 (-[WKThumbnailView _setThumbnailLayer:]):
3992 (-[WKThumbnailView _thumbnailLayer]):
3993 * UIProcess/API/Cocoa/WKThumbnailViewInternal.h:
3995 * UIProcess/API/mac/WKView.mm:
3996 (-[WKView _setAcceleratedCompositingModeRootLayer:]):
3997 (-[WKView _acceleratedCompositingModeRootLayer]):
3998 WKView should always keep track of the current root layer, instead of totally
3999 handing control over to WKThumbnailView when it is used.
4001 (-[WKView _setThumbnailView:]):
4002 (-[WKView _updateThumbnailViewLayer]):
4003 (-[WKView _reparentLayerTreeInThumbnailView]):
4004 If needed (either we're not using snapshots, or still waiting for the snapshot to be painted),
4005 push the WKView's live layer tree into the thumbnail view.
4007 * UIProcess/API/mac/WKViewInternal.h:
4008 * UIProcess/WebPageProxy.cpp:
4009 (WebKit::WebPageProxy::internalShowContextMenu):
4010 * UIProcess/WebPageProxy.h:
4011 * WebProcess/WebPage/WebPage.h:
4012 * WebProcess/WebPage/WebPage.messages.in:
4013 * WebProcess/WebPage/WebPage.cpp:
4014 (WebKit::WebPage::takeThumbnailSnapshot):
4015 Add a message that asynchronously returns a snapshot that respects the
4016 current thumbnail scale and position.
4018 (WebKit::WebPage::scaledSnapshotWithOptions):
4021 * WebProcess/WebPage/DrawingArea.cpp:
4022 (WebKit::DrawingArea::transform):
4023 * WebProcess/WebPage/DrawingArea.h:
4024 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
4025 Add a getter for the DrawingArea's transform.
4026 Rename it to rootLayerTransform.
4028 2014-03-17 Zan Dobersek <zdobersek@igalia.com>
4030 Use RunLoop objects through references instead of pointers
4031 https://bugs.webkit.org/show_bug.cgi?id=130313
4033 Reviewed by Andreas Kling.
4035 Adjust the code accordingly now that RunLoop::current() and RunLoop::main()
4036 return RunLoop reference instead of a pointer.
4038 * DatabaseProcess/DatabaseProcess.cpp:
4039 (WebKit::DatabaseProcess::didClose):
4040 (WebKit::DatabaseProcess::didReceiveInvalidMessage):
4041 * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
4042 (WebKit::UniqueIDBDatabase::postMainThreadTask):
4043 * NetworkProcess/NetworkProcess.cpp:
4044 (WebKit::NetworkProcess::didClose):
4045 (WebKit::NetworkProcess::didReceiveInvalidMessage):
4046 * NetworkProcess/NetworkResourceLoader.cpp:
4047 (WebKit::NetworkResourceLoader::continueWillSendRequest):
4048 * Platform/IPC/Connection.cpp:
4049 (IPC::Connection::SyncMessageState::getOrCreate):
4050 (IPC::Connection::SyncMessageState::SyncMessageState):
4051 (IPC::Connection::SyncMessageState::~SyncMessageState):
4052 (IPC::Connection::SyncMessageState::processIncomingMessage):
4053 (IPC::Connection::SyncMessageState::dispatchMessages):
4054 (IPC::Connection::createServerConnection):
4055 (IPC::Connection::createClientConnection):
4056 (IPC::Connection::Connection):
4057 (IPC::Connection::addWorkQueueMessageReceiver):
4058 (IPC::Connection::removeWorkQueueMessageReceiver):
4059 (IPC::Connection::sendSyncMessage):
4060 (IPC::Connection::sendSyncMessageFromSecondaryThread):
4061 (IPC::Connection::waitForSyncReply):
4062 (IPC::Connection::processIncomingMessage):
4063 (IPC::Connection::connectionDidClose):
4064 (IPC::Connection::dispatchDidReceiveInvalidMessage):
4065 (IPC::Connection::enqueueIncomingMessage):
4066 (IPC::Connection::wakeUpRunLoop):
4067 * Platform/IPC/Connection.h:
4068 * Platform/IPC/mac/ConnectionMac.cpp:
4069 (IPC::Connection::receiveSourceEventHandler):
4070 * Shared/ChildProcess.cpp:
4071 (WebKit::ChildProcess::stopRunLoop):
4072 * Shared/Plugins/NPObjectProxy.cpp:
4073 (WebKit::NPObjectProxy::NP_Deallocate):
4074 * UIProcess/Launcher/efl/ProcessLauncherEfl.cpp:
4075 (WebKit::ProcessLauncher::launchProcess):
4076 * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
4077 (WebKit::ProcessLauncher::launchProcess):
4078 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
4079 (WebKit::connectToService):
4080 (WebKit::tryPreexistingProcess):
4081 (WebKit::createProcess):
4082 * UIProcess/Storage/StorageManager.cpp:
4083 (WebKit::StorageManager::getOrigins):
4084 (WebKit::StorageManager::getStorageDetailsByOrigin):
4085 * UIProcess/Storage/StorageManager.h:
4086 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
4087 (WebKit::NetscapePlugin::pluginThreadAsyncCall):
4088 * WebProcess/Plugins/PluginView.cpp:
4089 (WebKit::PluginView::unprotectPluginFromDestruction):
4090 * WebProcess/WebPage/EventDispatcher.cpp:
4091 (WebKit::EventDispatcher::wheelEvent):
4092 * WebProcess/WebPage/ViewUpdateDispatcher.cpp:
4093 (WebKit::ViewUpdateDispatcher::visibleContentRectUpdate):
4094 * WebProcess/WebPage/WebPage.cpp:
4095 (WebKit::WebPage::close):
4097 2014-03-17 Giovanni Campagna <gcampagna@src.gnome.org>