1 2014-08-28 Tim Horton <timothy_horton@apple.com>
3 _setDidMoveSwipeSnapshotCallback's block should only be called if the snapshot is going to move
4 https://bugs.webkit.org/show_bug.cgi?id=136354
5 <rdar://problem/18167791>
7 Reviewed by Simon Fraser.
9 * UIProcess/API/Cocoa/WKViewPrivate.h:
10 Update the comment to note the new behavior.
12 * UIProcess/mac/ViewGestureControllerMac.mm:
13 (WebKit::ViewGestureController::beginSwipeGesture):
14 Don't call the block until the snapshot is actually moving (if the snapshot
15 never moves because it's behind the live view, don't call the block at all).
17 2014-08-28 Tim Horton <timothy_horton@apple.com>
19 Occasional thread-safety-related crashes on the ServicesController queue
20 https://bugs.webkit.org/show_bug.cgi?id=136356
21 <rdar://problem/18045685>
23 Reviewed by Dan Bernstein.
25 * UIProcess/mac/ServicesController.mm:
26 (WebKit::hasCompatibleServicesForItems):
27 Added. Check directly with NSSharingService if we have any services for the given items.
28 We should eventually check Viewer and Editor services separately so the Web process can
29 be smarter about when it shows the overlay, but for now this maintains the existing behavior.
31 (WebKit::ServicesController::refreshExistingServices):
32 Make use of hasCompatibleServicesForItems instead of having NSSharingServicePicker construct NSMenus.
34 2014-08-28 Tim Horton <timothy_horton@apple.com>
36 WebKit2 doesn't support viewer services that accept image attachments
37 https://bugs.webkit.org/show_bug.cgi?id=136349
38 <rdar://problem/18164606>
40 Reviewed by Brady Eidson.
42 * Shared/WebProcessCreationParameters.cpp:
43 (WebKit::WebProcessCreationParameters::encode):
44 (WebKit::WebProcessCreationParameters::decode):
45 Encode the already-existing parameter.
47 2014-08-28 Zalan Bujtas <zalan@apple.com>
49 Subpixel layout: Remove unused pixel snapping functions.
50 https://bugs.webkit.org/show_bug.cgi?id=136341
52 Reviewed by Simon Fraser.
54 Let's not encourage integral snapping by having these functions around.
56 No change in functionality.
58 * Shared/WebRenderObject.cpp:
59 (WebKit::WebRenderObject::WebRenderObject):
61 2014-08-27 Enrica Casucci <enrica@apple.com>
63 textStylingAtPosition returns incorrect values after executing toggleBold, toggleItalic and toggleUnderline.
64 https://bugs.webkit.org/show_bug.cgi?id=136323
65 rdar://problem/18141964
67 Reviewed by Antti Koivisto.
69 For underline style we need to check typingStyle first and use that information to populate
70 the dictionary. If there is no typing style we can use the render style.
71 We also need to update the editor state for the toggle commands to reflect the state in the UIProcess
72 even for commands that don't change the selection.
74 * WebProcess/WebPage/WebPage.cpp:
75 (WebKit::WebPage::editorState):
76 * WebProcess/WebPage/ios/WebPageIOS.mm:
77 (WebKit::WebPage::executeEditCommandWithCallback):
79 2014-08-28 Carlos Garcia Campos <cgarcia@igalia.com>
81 [GTK] Add webkit_uri_response_get_http_headers to WebKit2 GTK+ API
82 https://bugs.webkit.org/show_bug.cgi?id=136248
84 Reviewed by Gustavo Noronha Silva.
86 Add webkit_uri_response_get_http_headers() that returns the HTTP
87 headers as a SoupMessageHeaders* like webkit_uri_request_get_http_headers().
89 * UIProcess/API/gtk/WebKitURIResponse.cpp:
90 (webkitURIResponseGetProperty): Add http-headers property getter.
91 (webkit_uri_response_class_init): Add http-headers property.
92 (webkit_uri_response_get_http_headers): Return the HTTP headers as
93 a SoupMessageHeaders* or NULL for non HTTP responses.
94 * UIProcess/API/gtk/WebKitURIResponse.h:
95 * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbol.
97 2014-08-27 Zalan Bujtas <zalan@apple.com>
99 Subpixel layout: Rename LayoutRect's device pixel snapping functions.
100 https://bugs.webkit.org/show_bug.cgi?id=136319
102 Reviewed by Simon Fraser.
104 From pixelSnappedForPainting() to snapRectToDevicePixels() and
105 pixelSnappedIntRect*() to snappedIntRect*().
107 No change in functionality.
109 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
110 (WebKit::InjectedBundleNodeHandle::renderedImage):
111 * WebProcess/WebPage/WebPage.cpp:
112 (WebKit::WebPage::snapshotNode):
113 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
114 (WebKit::ServicesOverlayController::buildSelectionHighlight):
116 2014-08-27 Zalan Bujtas <zalan@apple.com>
118 Subpixel layout: Rename FloatPoint/FloatRect device pixel snapping functions.
119 https://bugs.webkit.org/show_bug.cgi?id=136314
121 Reviewed by Simon Fraser.
123 From *edToDevicePixels() to *PointToDevicePixels() (* = floor/round/ceil)
125 EnclosedIntRect -> enclosingIntRect() changes functionality for InspectorOverlay painting,
126 but currently untestable.
128 * UIProcess/ios/WKContentViewInteraction.mm:
129 (-[WKContentView _updateTapHighlight]):
131 2014-08-27 Tim Horton <timothy_horton@apple.com>
133 WebKit2 swipe gesture should report the position of the snapshot to the client
134 https://bugs.webkit.org/show_bug.cgi?id=136308
135 rdar://problem/18105827
137 Reviewed by Simon Fraser.
139 * UIProcess/API/Cocoa/WKViewPrivate.h:
140 * UIProcess/API/mac/WKView.mm:
141 (-[WKView _setDidMoveSwipeSnapshotCallback:]):
142 Add _setDidMoveSwipeSnapshotCallback, and plumb it to ViewGestureController.
143 Callers provide a block which is called whenever ViewGestureController moves the
144 swipe *snapshot* layer around.
146 * UIProcess/PageClient.h:
147 * UIProcess/WebPageProxy.h:
148 * UIProcess/mac/PageClientImpl.h:
149 * UIProcess/mac/PageClientImpl.mm:
150 (WebKit::PageClientImpl::boundsOfLayerInLayerBackedWindowCoordinates):
151 * UIProcess/mac/WebPageProxyMac.mm:
152 (WebKit::WebPageProxy::boundsOfLayerInLayerBackedWindowCoordinates):
153 Expose a Mac-only way to get the bounds of a given CALayer in window coordinates,
154 respecting transforms. This only works for layer-backed windows because
155 it uses CA in order to do the mapping respecting transforms.
157 * UIProcess/mac/ViewGestureController.h:
158 * UIProcess/mac/ViewGestureControllerMac.mm:
159 (WebKit::ViewGestureController::ViewGestureController):
160 (WebKit::ViewGestureController::~ViewGestureController):
161 (WebKit::ViewGestureController::setDidMoveSwipeSnapshotCallback):
162 Do the Block_copy and Block_release dance to keep our copy of the callback block.
164 (WebKit::ViewGestureController::beginSwipeGesture):
165 (WebKit::ViewGestureController::handleSwipeGesture):
166 (WebKit::ViewGestureController::didMoveSwipeSnapshotLayer):
167 When the swipe snapshot layer moves around, call the block.
169 2014-08-27 Tim Horton <timothy_horton@apple.com>
171 Occasional crashes in commitTransientZoom's transaction completion block
172 https://bugs.webkit.org/show_bug.cgi?id=136309
173 <rdar://problem/17215064>
175 Reviewed by Dan Bernstein.
177 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
178 (WebKit::TiledCoreAnimationDrawingArea::commitTransientZoom):
179 Hold a reference to zoomLayer and the WebPage. It's possible that either
180 of these things could have gone away by the time the transaction is committed.
182 2014-08-27 Benjamin Poulain <bpoulain@apple.com>
184 [iOS WK2] Provide a delegate callback to skip Geolocation authorization per page for WebApp
185 https://bugs.webkit.org/show_bug.cgi?id=136243
187 Reviewed by Sam Weinig.
189 Just ask the UI if the authorization dialog needs to be skipped.
191 * UIProcess/API/Cocoa/WKUIDelegate.h:
192 * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
193 * UIProcess/ios/PageClientImplIOS.mm:
194 (WebKit::PageClientImpl::decidePolicyForGeolocationPermissionRequest):
196 * UIProcess/ios/WKContentView.h:
197 * UIProcess/ios/WKContentView.mm:
198 (-[WKContentView _decidePolicyForGeolocationRequestFromOrigin:frame:request:]): Deleted.
199 The code in WKContentView only exists due to legacy. Instead, the PageClient dispatch the request
200 to the GeolocationProvider directly.
202 * UIProcess/ios/WKGeolocationProviderIOS.h:
203 * UIProcess/ios/WKGeolocationProviderIOS.mm:
204 (-[WKGeolocationProviderIOS decidePolicyForGeolocationRequestFromOrigin:frame:request:view:]):
205 (-[WKGeolocationProviderIOS geolocationAuthorizationGranted]):
206 (-[WKGeolocationProviderIOS positionChanged:]):
207 (-[WKGeolocationProviderIOS decidePolicyForGeolocationRequestFromOrigin:frame:request:window:]): Deleted.
209 2014-08-27 Beth Dakin <bdakin@apple.com>
211 overflow:scroll elements should not latch to the body if the body is
213 https://bugs.webkit.org/show_bug.cgi?id=136273
215 Reviewed by Darin Adler.
217 New ScrollabeArea virtual function.
218 * WebProcess/Plugins/PDF/PDFPlugin.h:
220 2014-08-26 Matt Lilek <mrl@apple.com>
222 Add WebKit SPI to control the navigator.standalone property
223 https://bugs.webkit.org/show_bug.cgi?id=136189
225 Reviewed by Andy Estes.
227 Add a property to WKPreferences that allows toggling this setting.
229 * UIProcess/API/Cocoa/WKPreferences.mm:
230 (-[WKPreferences _isStandalone]):
231 (-[WKPreferences _setStandalone:]):
232 * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
234 2014-08-26 Joseph Pecoraro <pecoraro@apple.com>
236 FileReader cannot read files selected with <input type="file"> in iOS 8
237 https://bugs.webkit.org/show_bug.cgi?id=136117
239 Reviewed by Alexey Proskuryakov.
241 * Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:
242 Correct an overzealous deny that was accidentally denying all
243 com.apple.app-sandbox.read extensions instead of just the ones
244 in Application bundles it was trying to deny.
246 2014-08-26 Tim Horton <timothy_horton@apple.com>
248 Crashes in ViewGestureController::beginSwipeGesture when swiping in rapid succession
249 https://bugs.webkit.org/show_bug.cgi?id=136271
250 <rdar://problem/17923694>
252 Reviewed by Simon Fraser.
254 It was possible to get into trackSwipeGesture while another swipe was still
255 occurring, because the guard against this happening depended on m_pendingSwipeReason
256 never being set while a swipe was occurring. However, if the very first scroll event
257 had sufficient magnitude, we would still set m_pendingSwipeReason to InsufficientMagnitude,
258 and then *never clear it*, leading to a path around the guard against multiple live swipes.
259 This in turn allowed stale layers in m_liveSwipeLayers, which lead to the crash.
261 * UIProcess/mac/ViewGestureControllerMac.mm:
262 (WebKit::ViewGestureController::handleScrollWheelEvent):
263 Don't unset m_pendingSwipeReason before calling trackSwipeGesture;
264 trackSwipeGesture will do it itself.
266 Don't set m_pendingSwipeReason to InsufficientMagnitude
267 if the event actually *has* sufficient magnitude to start a swipe.
269 (WebKit::ViewGestureController::trackSwipeGesture):
270 Assert that we don't have an active gesture while starting a swipe.
272 Reset m_pendingSwipeReason, because the swipe is no longer pending!
274 2014-08-26 Andy Estes <aestes@apple.com>
276 [Cocoa] Some projects are incorrectly installed to $BUILT_PRODUCTS_DIR
277 https://bugs.webkit.org/show_bug.cgi?id=136267
279 Reviewed by Dan Bernstein.
281 INSTALL_PATH was set to $BUILT_PRODUCTS_DIR for engineering configurations in r20225 as part of a build fix.
282 Not only is this no longer necessary to build, but it causes built products to be incorrectly installed in
283 engineering configurations.
285 Remove the setting of INSTALL_PATH from the pbxproj file so that the value specified in the xcconfig files is
288 * WebKit2.xcodeproj/project.pbxproj:
290 2014-08-25 Maciej Stachowiak <mjs@apple.com>
292 Replace use of WKCopyCFLocalizationPreferredName with NSLocale public API
293 https://bugs.webkit.org/show_bug.cgi?id=136082
295 Reviewed by Alexey Proskuryakov.
297 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
298 (WebKit::connectToService): Remove accidental leftover retrieval
300 (WebKit::createProcess): Get current localization name from
301 CFBundle API instead of using SPI.
302 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
303 (InitWebCoreSystemInterface): Remove mention of WKCopyCFLocalizationPreferredName
304 * mac/WebKit2.order: ditto
306 2014-08-26 Dana Burkart <dburkart@apple.com>
308 The UNUSED_PARAM macros in ServicesOverlayController.mm are causing ASan build failures.
309 https://bugs.webkit.org/show_bug.cgi?id=136262
311 Reviewed by David Kilzer.
313 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
314 (WebKit::ServicesOverlayController::selectionRectsDidChange):
315 (WebKit::ServicesOverlayController::selectedTelephoneNumberRangesChanged):
317 2014-08-26 Csaba Osztrogonác <ossy@webkit.org>
319 [EFL] URTBF after r172966.
321 * UIProcess/efl/WebViewEfl.h:
323 2014-08-26 Carlos Alberto Lopez Perez <clopez@igalia.com>
325 REGRESSION(r172966) [GTK] Build broken.
327 Unreviewed build fix after r172966.
329 * UIProcess/API/gtk/PageClientImpl.cpp:
330 (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
331 * UIProcess/API/gtk/PageClientImpl.h:
333 2014-08-26 Simon Fraser <simon.fraser@apple.com>
335 Crashes in hit testing under WebPage::determinePrimarySnapshottedPlugIn()
336 https://bugs.webkit.org/show_bug.cgi?id=136240
337 rdar://problem/17231462
339 Reviewed by Darin Adler.
341 determinePrimarySnapshottedPlugIn() does render tree hit testing, so needs
342 to ensure that layout is up-to-date.
344 * WebProcess/WebPage/WebPage.cpp:
345 (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
347 2014-08-26 Tim Horton <timothy_horton@apple.com>
349 REGRESSION (r172771): Amazon product page becomes unresponsive after swiping back to it
350 https://bugs.webkit.org/show_bug.cgi?id=136260
351 <rdar://problem/18107826>
353 Reviewed by Dan Bernstein.
355 Previously, when a swipe ended up performing a same-document navigation,
356 we would never get didFinishLoadForMainFrame nor didFirstVisuallyNonEmptyLayoutForMainFrame
357 nor would we even get didHitRenderTreeSizeThreshold in all cases, so we would never
358 remove the swipe snapshot. Previous implementations removed the snapshot on
359 didSameDocumentNavigation for the main frame if the navigation type was Replace or Pop,
360 so we will match that behavior.
362 Also, reinstate the watchdog that starts at swipe-end which would have prevented
363 this bug from forever breaking the view it was associated with.
365 Also, defend against removing the snapshot before the swipe has finished (before
366 we have even caused the navigation that we're watching for the effects of).
368 * UIProcess/API/mac/WKView.mm:
369 (-[WKView _didSameDocumentNavigationForMainFrame:]):
370 * UIProcess/API/mac/WKViewInternal.h:
371 * UIProcess/PageClient.h:
372 * UIProcess/WebPageProxy.cpp:
373 (WebKit::WebPageProxy::didSameDocumentNavigationForFrame):
374 * UIProcess/ios/PageClientImplIOS.h:
375 * UIProcess/ios/PageClientImplIOS.mm:
376 (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
377 * UIProcess/mac/PageClientImpl.h:
378 * UIProcess/mac/PageClientImpl.mm:
379 (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
380 Plumb main-frame same-document navigation notification from WebPageProxy
381 to ViewGestureControllerMac via PageClient and WKView.
383 * UIProcess/mac/ViewGestureController.h:
384 * UIProcess/mac/ViewGestureControllerMac.mm:
385 (WebKit::ViewGestureController::ViewGestureController):
386 (WebKit::ViewGestureController::beginSwipeGesture):
387 (WebKit::ViewGestureController::endSwipeGesture):
388 Keep track of whether a swipe is currently occurring. We can't use
389 activeGestureType for this because the swipe currently remains the "active"
390 gesture until the snapshot is removed.
392 Reintroduce the old swipeWatchdogTimer (and rename the shorter timer that starts
393 when we get a visually non-empty layout) so that we will always remove the
394 snapshot after 5 seconds, even if we haven't committed the load.
395 This could lead to flashing back to the old content if we fail to get a single
396 byte for 5 seconds, but that is a rare case and should eventually get additional
397 special treatment (dropping the tiles until we do get content, or some such).
399 (WebKit::ViewGestureController::didHitRenderTreeSizeThreshold):
400 If a swipe is still in progress, we haven't done our navigation and thus
401 don't care about render tree size changes.
403 (WebKit::ViewGestureController::didFirstVisuallyNonEmptyLayoutForMainFrame):
404 If a swipe is still in progress, we haven't done our navigation and thus
405 don't care about layouts.
407 Stop the 5 second overall watchdog if we start the 3 second after-visuallyNonEmptyLayout
408 watchdog. This means that the snapshot could stay up for a maximum of 8 seconds
409 for a very, very slow load.
411 (WebKit::ViewGestureController::didFinishLoadForMainFrame):
412 If a swipe is still in progress, we haven't done our navigation and thus
413 don't care about loads that complete.
415 (WebKit::ViewGestureController::didSameDocumentNavigationForMainFrame):
416 Remove the swipe snapshot after painting if we do replaceState or popState.
418 (WebKit::ViewGestureController::removeSwipeSnapshotAfterRepaint):
419 If a swipe is still in progress, we shouldn't remove the snapshot yet.
421 2014-08-26 Carlos Garcia Campos <cgarcia@igalia.com>
423 [GTK] Translations are not initialized in the UI process
424 https://bugs.webkit.org/show_bug.cgi?id=136249
426 Reviewed by Philippe Normand.
428 This is breaking things like webkitContextMenuActionGetForContextMenuItem()
429 for non English locales in the cases where we use the action title to guess the
430 action, because the action title we get from the web process is translated while
431 the one in the UI process is in English.
433 * UIProcess/API/gtk/WebKitWebContext.cpp:
434 (createDefaultWebContext): Initialize gettext right before
435 creating the default web context.
437 2014-08-26 Ryuan Choi <ryuan.choi@samsung.com>
439 [EFL] Remove dead code in WebPageEfl.cpp
440 https://bugs.webkit.org/show_bug.cgi?id=136246
442 Reviewed by Gyuyoung Kim.
444 * WebProcess/WebPage/efl/WebPageEfl.cpp:
445 (WebKit::scroll): Deleted.
447 2014-08-26 Ryuan Choi <ryuan.choi@samsung.com>
449 [EFL] Build break using clang
450 https://bugs.webkit.org/show_bug.cgi?id=136245
452 Reviewed by Gyuyoung Kim.
454 * PlatformEfl.cmake: defines GTEST_HAS_RTTI=0
456 2014-08-25 Zalan Bujtas <zalan@apple.com>
458 Subpixel layout: remove roundedLayoutPoint/roundedLayoutSize functions.
459 https://bugs.webkit.org/show_bug.cgi?id=136236
461 Reviewed by Simon Fraser.
463 These functions simply call LayoutPoint/LayoutSize c'tors. They don't round the input value at all.
465 Non change in functionality.
467 * UIProcess/ios/WebPageProxyIOS.mm:
468 (WebKit::WebPageProxy::computeCustomFixedPositionRect):
470 2014-08-25 Antti Koivisto <antti@apple.com>
472 Don't pass priority as parameter to ResourceLoadScheduler
473 https://bugs.webkit.org/show_bug.cgi?id=136232
475 Reviewed by Sam Weinig.
477 * NetworkProcess/NetworkResourceLoader.cpp:
478 (WebKit::NetworkResourceLoader::NetworkResourceLoader):
479 * NetworkProcess/NetworkResourceLoader.h:
480 (WebKit::NetworkResourceLoader::priority): Deleted.
481 * Shared/Network/NetworkResourceLoadParameters.cpp:
482 (WebKit::NetworkResourceLoadParameters::NetworkResourceLoadParameters):
483 (WebKit::NetworkResourceLoadParameters::encode):
484 (WebKit::NetworkResourceLoadParameters::decode):
485 * Shared/Network/NetworkResourceLoadParameters.h:
486 * WebProcess/Network/WebResourceLoadScheduler.cpp:
487 (WebKit::WebResourceLoadScheduler::scheduleSubresourceLoad):
488 (WebKit::WebResourceLoadScheduler::schedulePluginStreamLoad):
489 (WebKit::WebResourceLoadScheduler::scheduleLoad):
490 * WebProcess/Network/WebResourceLoadScheduler.h:
491 * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
492 (WebKit::WebPlatformStrategies::loadResourceSynchronously):
494 2014-08-25 Brady Eidson <beidson@apple.com>
496 Don't crash when the DataDetectors framework is unavailable.
497 <rdar://problem/18106066> and https://bugs.webkit.org/show_bug.cgi?id=136234
499 Reviewed by Tim Horton.
501 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
502 (WebKit::ServicesOverlayController::buildPhoneNumberHighlights): Bail if DD.framework didn’t soft link.
503 (WebKit::ServicesOverlayController::buildSelectionHighlight): Ditto.
505 2014-08-25 Antti Koivisto <antti@apple.com>
507 Remove load scheduling code from network process
508 https://bugs.webkit.org/show_bug.cgi?id=136199
510 Reviewed by Darin Adler.
512 Most platforms just flush resource loads directly to the networking layer by
513 making the parallel load count large. Also we always pass ResourceLoadPriorityHighest
514 to the scheduler so no actual scheduling happens. This is effectively dead code.
516 Keep basic support for serializing loads. This is only used for testing.
518 * NetworkProcess/HostRecord.cpp: Removed.
519 * NetworkProcess/HostRecord.h: Removed.
520 * NetworkProcess/NetworkConnectionToWebProcess.cpp:
521 (WebKit::NetworkConnectionToWebProcess::servePendingRequests):
522 * NetworkProcess/NetworkProcess.cpp:
523 (WebKit::NetworkProcess::getNetworkProcessStatistics):
524 * NetworkProcess/NetworkResourceLoadScheduler.cpp:
525 (WebKit::NetworkResourceLoadScheduler::NetworkResourceLoadScheduler):
526 (WebKit::NetworkResourceLoadScheduler::scheduleLoader):
527 (WebKit::NetworkResourceLoadScheduler::removeLoader):
528 (WebKit::NetworkResourceLoadScheduler::loadsPendingCount):
529 (WebKit::NetworkResourceLoadScheduler::loadsActiveCount):
530 (WebKit::NetworkResourceLoadScheduler::scheduleServePendingRequests): Deleted.
531 (WebKit::NetworkResourceLoadScheduler::requestTimerFired): Deleted.
532 (WebKit::NetworkResourceLoadScheduler::hostForURL): Deleted.
533 (WebKit::NetworkResourceLoadScheduler::receivedRedirect): Deleted.
534 (WebKit::NetworkResourceLoadScheduler::servePendingRequests): Deleted.
535 (WebKit::NetworkResourceLoadScheduler::removeScheduledLoaders): Deleted.
536 (WebKit::NetworkResourceLoadScheduler::scheduleRemoveLoader): Deleted.
537 (WebKit::NetworkResourceLoadScheduler::hostsPendingCount): Deleted.
538 (WebKit::NetworkResourceLoadScheduler::hostsActiveCount): Deleted.
539 * NetworkProcess/NetworkResourceLoadScheduler.h:
540 * NetworkProcess/NetworkResourceLoader.cpp:
541 (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
542 (WebKit::NetworkResourceLoader::cleanup):
543 (WebKit::NetworkResourceLoader::continueWillSendRequest):
544 * NetworkProcess/NetworkResourceLoader.h:
545 (WebKit::NetworkResourceLoader::isLoadingMainResource):
546 (WebKit::NetworkResourceLoader::setHostRecord): Deleted.
547 (WebKit::NetworkResourceLoader::hostRecord): Deleted.
548 * NetworkProcess/mac/NetworkResourceLoadSchedulerMac.mm:
549 (WebKit::NetworkResourceLoadScheduler::platformInitializeNetworkSettings):
550 (WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost): Deleted.
551 * NetworkProcess/soup/NetworkResourceLoadSchedulerSoup.cpp:
552 (WebKit::NetworkResourceLoadScheduler::platformInitializeNetworkSettings):
553 (WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost): Deleted.
554 * WebKit2.xcodeproj/project.pbxproj:
556 2014-08-25 Carlos Garcia Campos <cgarcia@igalia.com>
558 [GTK] Older versions of WebKit should use the plugins cache in read only mode
559 https://bugs.webkit.org/show_bug.cgi?id=136215
561 Reviewed by Philippe Normand.
563 Now that WebKitGTK+ 2.4 and 2.5 are parallel installable, since
564 they use different versions of the plugins cache, apps using 2.4
565 might override the plugins cache file. We should prevent this from
566 happening by making older versions use the plugin cache, but not
569 * UIProcess/Plugins/gtk/PluginInfoCache.cpp:
570 (WebKit::PluginInfoCache::PluginInfoCache):
571 (WebKit::PluginInfoCache::updatePluginInfo):
572 * UIProcess/Plugins/gtk/PluginInfoCache.h:
574 2014-08-25 Carlos Garcia Campos <cgarcia@igalia.com>
576 [GTK] Should check if a plugin mixes GTK+ symbols earlier
577 https://bugs.webkit.org/show_bug.cgi?id=136214
579 Reviewed by Philippe Normand.
581 We are currently checking if the plugin module and the plugin
582 process mix GTK symbols after the plugin has been loaded and
583 initialized. This is too late in many cases, since plugins can use
584 GTK methods in the NP_Initialize implementation. This is causing
585 the apps using WebKitGTK+ 2.4 to freeze when the plugin process
586 scans the plugins and there's a plugin using GTK+3 installed. We
587 should move the check earlier, once the module is loaded but
588 before calling NP_Initialize.
590 * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
591 (WebKit::moduleMixesGtkSymbols):
592 (WebKit::NetscapePluginModule::tryLoad):
593 * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
594 (WebKit::NetscapePlugin::platformPostInitialize):
596 2014-08-25 Zan Dobersek <zdobersek@igalia.com>
598 Improve virtual method declarations in LayerTreeHostGtk
599 https://bugs.webkit.org/show_bug.cgi?id=136210
601 Reviewed by Carlos Garcia Campos.
603 Mark the LayerTreeHostGtk class as final in the virtual inheritance hierarchy.
605 Order the public and private virtual method overrides from the LayerTreeHost
606 and GraphicsLayerClient interfaces. Explicitly mark them as overriding the
609 Remove the overriding notifyAnimationStarted() and notifyFlushRequired()
610 methods since they are identical to the methods in the base class.
612 De-virtualize flushPendingLayerChanges(). It's not inherited and is not
613 overriden by anything (and nothing can inherit from LayerTreeHostGtk from
614 now on due to the final specifier).
616 * WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
617 (WebKit::LayerTreeHostGtk::notifyAnimationStarted): Deleted.
618 (WebKit::LayerTreeHostGtk::notifyFlushRequired): Deleted.
619 * WebProcess/WebPage/gtk/LayerTreeHostGtk.h:
620 (WebKit::LayerTreeHostGtk::didCommitChangesForLayer): Deleted.
622 2014-08-24 Brian J. Burg <burg@cs.washington.edu>
624 Remove unused method declarations replaced by WebPage::setViewState
625 https://bugs.webkit.org/show_bug.cgi?id=136180
627 Reviewed by Darin Adler.
629 * WebProcess/WebPage/WebPage.h:
630 Remove setFocused, setActive, setViewIsVisible. No longer used.
632 2014-08-23 Byungseon Shin <sun.shin@lge.com>
634 Unify GraphicsLayer::setContentsToMedia and setContentsToCanvas
635 https://bugs.webkit.org/show_bug.cgi?id=109658
637 Reviewed by Martin Robinson.
639 Based on patch originally written by Tim Horton.
640 Merge setContentsToMedia and setContentsToCanvas into setContentsToPlatformLayer.
642 * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
643 (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::encode):
644 (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::decode):
645 Rename canvas -> platformLayer.
647 2014-08-22 Commit Queue <commit-queue@webkit.org>
649 Unreviewed, rolling out r172866.
650 https://bugs.webkit.org/show_bug.cgi?id=136177
652 Broke iOS build (Requested by othermaciej on #webkit).
656 "Replace use of WKCopyCFLocalizationPreferredName with
658 https://bugs.webkit.org/show_bug.cgi?id=136082
659 http://trac.webkit.org/changeset/172866
661 2014-08-19 Maciej Stachowiak <mjs@apple.com>
663 Replace use of WKCopyCFLocalizationPreferredName with NSLocale public API
664 https://bugs.webkit.org/show_bug.cgi?id=136082
666 Reviewed by Alexey Proskuryakov.
668 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
669 (WebKit::connectToService): Remove accidental leftover retrieval
671 (WebKit::createProcess): Get current localization name from
672 CFBundle API instead of using SPI.
673 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
674 (InitWebCoreSystemInterface): Remove mention of WKCopyCFLocalizationPreferredName
675 * mac/WebKit2.order: ditto
677 2014-08-22 Daniel Bates <dabates@apple.com>
679 [iOS] Disable ENABLE_IOS_{GESTURE, TOUCH}_EVENTS, and temporarily disable ENABLE_TOUCH_EVENTS
680 and ENABLE_XSLT when building with the iOS public SDK
681 https://bugs.webkit.org/show_bug.cgi?id=135945
683 Reviewed by Andy Estes.
685 * Configurations/FeatureDefines.xcconfig: Disable ENABLE_IOS_{GESTURE, TOUCH}_EVENTS, ENABLE_TOUCH_EVENTS
686 and ENABLE_XSLT when building with the public SDK.
687 * Shared/WebEventConversion.h: Write preprocessor logic in terms of ENABLE(IOS_TOUCH_EVENTS).
688 * WebProcess/WebPage/WebPage.h: Ditto.
690 2014-08-22 Simon Fraser <simon.fraser@apple.com>
692 Implement paint flashing via GraphicsLayers in the WK2 inspector overlay
693 https://bugs.webkit.org/show_bug.cgi?id=136136
695 Reviewed by Sam Weinig, Joseph Pecoraro.
697 Allow InspectorClient to have a custom implementation of showPaintRect(). For
698 WebKit2's WebInspectorClient, implement this by creating a set of GraphicsLayers
699 which are parented in a document overlay, with 0.25s fade-out animations.
701 Also change InspectorInstrumentation::didPaintImpl() to no longer take a GraphicsContext;
702 it makes no sense to paint the paint rects directly into the context of the web page.
703 Now that the paint rects are painted into an overlay, the rectangles need to be converted
704 to root document coordinates, which is done in InspectorInstrumentation::didPaintImpl().
706 Remove the generic InspectorOverlay::drawOutline()-based indicators; they will
707 be reimplemented in a later patch.
709 * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
710 (WebKit::RepaintIndicatorLayerClient::RepaintIndicatorLayerClient):
711 (WebKit::RepaintIndicatorLayerClient::~RepaintIndicatorLayerClient):
712 (WebKit::RepaintIndicatorLayerClient::notifyAnimationEnded):
713 (WebKit::WebInspectorClient::WebInspectorClient):
714 (WebKit::WebInspectorClient::~WebInspectorClient):
715 (WebKit::WebInspectorClient::showPaintRect):
716 (WebKit::WebInspectorClient::animationEndedForLayer):
717 * WebProcess/WebCoreSupport/WebInspectorClient.h:
718 (WebKit::WebInspectorClient::WebInspectorClient): Deleted.
720 2014-08-22 Jon Lee <jonlee@apple.com>
722 Fix iOS build due to r172832 and move RUBBER_BANDING out of FeatureDefines.h
723 https://bugs.webkit.org/show_bug.cgi?id=136157
725 Reviewed by Simon Fraser.
727 * Configurations/FeatureDefines.xcconfig: Add ENABLE(RUBBER_BANDING).
729 2014-08-21 Joseph Pecoraro <pecoraro@apple.com>
731 Possible RetainPtr misuse in WKScriptMessage.mm - could leak
732 https://bugs.webkit.org/show_bug.cgi?id=136140
734 Reviewed by Darin Adler.
736 Adopt a copy into a RetainPtr to avoid leaking.
738 * UIProcess/API/Cocoa/WKScriptMessage.mm:
739 (-[WKScriptMessage _initWithBody:webView:frameInfo:name:]):
741 2014-08-21 Simon Fraser <simon.fraser@apple.com>
743 Add animationDidEnd callbacks on GraphicsLayer
744 https://bugs.webkit.org/show_bug.cgi?id=136084
746 Reviewed by Tim Horton.
748 Hook up GraphicsLayerClient::notifyAnimationEnded() so that code using GraphicsLayers directly
749 can add animations, and know when they finish.
751 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h:
752 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
753 (WebKit::RemoteLayerTreeDrawingAreaProxy::acceleratedAnimationDidEnd):
754 * UIProcess/mac/RemoteLayerTreeHost.h:
755 * UIProcess/mac/RemoteLayerTreeHost.mm:
756 (WebKit::RemoteLayerTreeHost::animationDidEnd):
757 * WebProcess/WebPage/DrawingArea.h:
758 (WebKit::DrawingArea::acceleratedAnimationDidEnd):
759 * WebProcess/WebPage/DrawingArea.messages.in:
760 * WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm:
761 (-[WKAnimationDelegate animationDidStop:finished:]):
762 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
763 (WebKit::PlatformCALayerRemote::animationStarted):
764 (WebKit::PlatformCALayerRemote::animationEnded):
765 * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
766 * WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
767 * WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
768 (WebKit::RemoteLayerTreeContext::layerWillBeDestroyed):
769 (WebKit::RemoteLayerTreeContext::willStartAnimationOnLayer):
770 (WebKit::RemoteLayerTreeContext::animationDidStart):
771 (WebKit::RemoteLayerTreeContext::animationDidEnd):
772 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
773 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
774 (WebKit::RemoteLayerTreeDrawingArea::acceleratedAnimationDidEnd):
776 2014-08-21 Zalan Bujtas <zalan@apple.com>
778 Enable SATURATED_LAYOUT_ARITHMETIC.
779 https://bugs.webkit.org/show_bug.cgi?id=136106
781 Reviewed by Simon Fraser.
783 SATURATED_LAYOUT_ARITHMETIC protects LayoutUnit against arithmetic overflow.
784 (No measurable performance regression on Mac.)
786 * Configurations/FeatureDefines.xcconfig:
788 2014-08-21 Víctor Manuel Jáquez Leal <vjaquez@igalia.com>
790 [GTK] WebkitWebProcess crashing navigating away from ogg video element
791 https://bugs.webkit.org/show_bug.cgi?id=135348
793 Reviewed by Philippe Normand.
795 When a page is cached, by default doesn't recreate the backing store
796 (an optimization added in r89316).
798 Not all the ports uses that optimization. For example IOS port doesn't
801 In the case of the GTK port, the MediaPlayerPrivateGStreamer, not only
802 processes video buffers, also display them, because it is a
803 TextureMapperPlatformLayer too.
805 Nevertheless, in r153937, when a page is cached, the player is
806 destroyed. But our player has a backing store and the render tree
807 doesn't know that the player has gone. Hence, when the page is redraw,
808 the TextureMapper tree visits the video element, which doesn't exist
809 anymore, a segmentation fault occurs.
811 So, as our media player renders, and as we cannot trust that the
812 player exists when a page is painted, we cannot rely in the r89316
815 Disabling the backing stores optimization fixes the problem.
817 Covered by existing tests.
819 * WebProcess/soup/WebProcessSoup.cpp:
820 (WebKit::WebProcess::platformSetCacheModel): Enable the backing store
821 clearing when page caching for GTK.
823 2014-08-20 Alex Christensen <achristensen@webkit.org>
825 Introducing WEBCORE_EXPORT macro.
826 https://bugs.webkit.org/show_bug.cgi?id=136108
828 Reviewed by Antti Koivisto.
831 Added stub definition of WEBCORE_EXPORT defined to nothing to be able to compile with WebCore headers.
833 2014-08-20 Pratik Solanki <psolanki@apple.com>
835 Move DiskCacheMonitor to WebCore so that WebKit1 clients can use it as well
836 https://bugs.webkit.org/show_bug.cgi?id=135896
838 Reviewed by Andreas Kling.
840 * NetworkProcess/mac/NetworkDiskCacheMonitor.h:
841 Inherit from WebCore::DiskCacheMonitor which has the bulk of the functionality now.
842 (WebKit::NetworkDiskCacheMonitor::~NetworkDiskCacheMonitor):
843 * NetworkProcess/mac/NetworkDiskCacheMonitor.mm:
844 (WebKit::NetworkDiskCacheMonitor::monitorFileBackingStoreCreation):
845 (WebKit::NetworkDiskCacheMonitor::NetworkDiskCacheMonitor):
846 (WebKit::NetworkDiskCacheMonitor::resourceBecameFileBacked):
847 Override virtual method and send the data to the WebContent process as before.
849 2014-08-19 Pratik Solanki <psolanki@apple.com>
851 Remove PurgeableBuffer since it is not very useful any more
852 https://bugs.webkit.org/show_bug.cgi?id=135939
854 Reviewed by Andreas Kling.
856 * WebProcess/WebProcess.cpp:
857 (WebKit::getWebCoreMemoryCacheStatistics):
859 2014-08-19 Peyton Randolph <prandolph@apple.com>
861 Expose injected bundle SPI to get a node's URL element, get the visible selection range of that
862 element, and snapshot that range
863 https://bugs.webkit.org/show_bug.cgi?id=136076
865 Reviewed by Tim Horton.
867 * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
868 (WKBundleHitTestResultCopyURLElementHandle): Added.
869 * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
870 * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
871 (WKBundleNodeHandleCopyVisibleRange): Added.
872 * WebProcess/InjectedBundle/API/c/WKBundleNodeHandlePrivate.h:
873 * WebProcess/InjectedBundle/API/c/WKBundleRangeHandle.cpp:
874 (WKBundleRangeHandleGetBoundingRectInWindowCoordinates): Added.
875 (WKBundleRangeHandleCopySnapshotWithOptions): Added.
876 * WebProcess/InjectedBundle/API/c/WKBundleRangeHandlePrivate.h:
877 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
878 (WebKit::InjectedBundleNodeHandle::visibleRange): Added.
879 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:
880 * WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.cpp:
881 (WebKit::InjectedBundleRangeHandle::boundingRectInWindowCoordinates): Added.
882 (WebKit::InjectedBundleRangeHandle::renderedImage): Added.
883 * WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.h:
884 * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
885 (WebKit::InjectedBundleHitTestResult::urlElementHandle): Added.
886 * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
888 2014-08-19 Zalan Bujtas <zalan@apple.com>
890 Remove ENABLE(SUBPIXEL_LAYOUT).
891 https://bugs.webkit.org/show_bug.cgi?id=136077
893 Reviewed by Simon Fraser.
895 Remove compile time flag SUBPIXEL_LAYOUT. All ports have it enabled for a while now.
897 * Configurations/FeatureDefines.xcconfig:
899 2014-08-19 Peyton Randolph <prandolph@apple.com>
901 Extend injected bundle node snapshotting to support forced white and black text
902 https://bugs.webkit.org/show_bug.cgi?id=136061
904 Reviewed by Beth Dakin.
906 * Shared/API/c/WKImage.h:
907 Add -ForceBlackText and -ForceWhiteText snapshotting options.
908 * Shared/API/c/WKSharedAPICast.h:
909 (WebKit::toSnapshotOptions):
910 Support aforementioned text snapshotting options.
911 * Shared/ImageOptions.h:
912 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
913 (WebKit::imageForRect):
914 Respect text color snapshotting options by setting appropriate paint behaviors.
916 2014-08-18 Maciej Stachowiak <mjs@apple.com>
918 Use NSURLFileTypeMappings directly instead of depending on WebKitSystemInterface wrappers for it
919 https://bugs.webkit.org/show_bug.cgi?id=136035
921 Reviewed by Dan Bernstein.
923 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
924 (InitWebCoreSystemInterface): Don't initialize the no-longer-used WKGetExtensionsForMIMEType,
925 WKGetPreferredExtensionForMIMEType, or WKGetMIMETypeForExtension
926 * mac/WebKit2.order: Remove exports related to above.
928 2014-08-18 Commit Queue <commit-queue@webkit.org>
930 Unreviewed, rolling out r172736.
931 https://bugs.webkit.org/show_bug.cgi?id=136060
933 Caused 14% PLT regressions (Requested by rniwa on #webkit).
937 "Remove PurgeableBuffer since it is not very useful any more"
938 https://bugs.webkit.org/show_bug.cgi?id=135939
939 http://trac.webkit.org/changeset/172736
941 2014-08-18 Simon Fraser <simon.fraser@apple.com>
943 Provide default implementations of all GraphicsLayerClient methods
944 https://bugs.webkit.org/show_bug.cgi?id=136054
946 Reviewed by Tim Horton.
948 Remove overrides which are no longer required.
950 * WebProcess/WebPage/PageOverlayController.h:
951 * WebProcess/WebPage/ServicesOverlayController.h:
952 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
954 2014-08-18 Pratik Solanki <psolanki@apple.com>
956 Remove PurgeableBuffer since it is not very useful any more
957 https://bugs.webkit.org/show_bug.cgi?id=135939
959 Reviewed by Geoffrey Garen.
961 * WebProcess/WebProcess.cpp:
962 (WebKit::getWebCoreMemoryCacheStatistics):
964 2014-08-18 Peyton Randolph <prandolph@apple.com>
966 Expose long mouse press WebKit API. Part of 135257 - Add long mouse press gesture
967 https://bugs.webkit.org/show_bug.cgi?id=136048
969 Reviewed by Dan Bernstein.
971 This patch exposes long mouse press API callbacks in both the injected bundle and on the UI process
972 through their respective page UI clients. The callbacks are modeled off of the mouseDidMoveOverElement
973 callback. Like the mouseDidMoveOverElement callback, these callbacks allow the bundle to pass
974 information to the UI process via a userData out parameter.
976 * UIProcess/API/APIUIClient.h:
977 (API::UIClient::didBeginTrackingPotentialLongMousePress): Added.
978 (API::UIClient::didRecognizeLongMousePress): Added.
979 (API::UIClient::didCancelTrackingPotentialLongMousePress): Added.
980 * UIProcess/API/C/WKPage.cpp:
981 (WKPageSetPageUIClient):
982 * UIProcess/API/C/WKPageUIClient.h:
983 * UIProcess/WebPageProxy.cpp:
984 (WebKit::WebPageProxy::didBeginTrackingPotentialLongMousePress): Added.
985 (WebKit::WebPageProxy::didRecognizeLongMousePress): Added.
986 (WebKit::WebPageProxy::didCancelTrackingPotentialLongMousePress): Added.
987 * UIProcess/WebPageProxy.h:
988 * UIProcess/WebPageProxy.messages.in:
989 * WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h:
990 (API::InjectedBundle::PageUIClient::didBeginTrackingPotentialLongMousePress): Added.
991 (API::InjectedBundle::PageUIClient::didRecognizeLongMousePress): Added.
992 (API::InjectedBundle::PageUIClient::didCancelTrackingPotentialLongMousePress): Added.
993 * WebProcess/InjectedBundle/API/c/WKBundlePageUIClient.h:
994 * WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp: Added.
995 (WebKit::InjectedBundlePageUIClient::didBeginTrackingPotentialLongMousePress): Added.
996 (WebKit::InjectedBundlePageUIClient::didRecognizeLongMousePress): Added.
997 (WebKit::InjectedBundlePageUIClient::didCancelTrackingPotentialLongMousePress): Added.
998 * WebProcess/InjectedBundle/InjectedBundlePageUIClient.h:
999 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1000 (WebKit::WebChromeClient::didBeginTrackingPotentialLongMousePress): Added.
1001 (WebKit::WebChromeClient::didRecognizeLongMousePress): Added.
1002 (WebKit::WebChromeClient::didCancelTrackingPotentialLongMousePress): Added.
1003 * WebProcess/WebCoreSupport/WebChromeClient.h:
1005 2014-08-18 Przemyslaw Kuczynski <p.kuczynski@samsung.com>
1007 Fix unintentional integer overflow before widen
1008 https://bugs.webkit.org/show_bug.cgi?id=135463
1010 Reviewed by Oliver Hunt.
1012 Overflowing expression is evaluated using operands arithmetic but then is used in
1013 context which expects an wider integer type. To avoid overflow at least one operand
1014 has to be representative of the wider type.
1016 * WebProcess/soup/WebProcessSoup.cpp:
1017 (WebKit::getMemorySize): Added long long literal.
1019 2014-08-18 Przemyslaw Kuczynski <p.kuczynski@samsung.com>
1021 Fix resource leak in unclosed file descriptor handles
1022 https://bugs.webkit.org/show_bug.cgi?id=135458
1024 Reviewed by Oliver Hunt.
1026 Leaving descriptor unclosed will cause the resources associated with the open
1027 file description never be freed (they are freed on closing the last descriptor
1028 refering to the underlying file).
1030 * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
1031 (WebKit::StdoutDevNullRedirector::StdoutDevNullRedirector): Closed newStdout descriptor.
1032 (WebKit::StdoutDevNullRedirector::~StdoutDevNullRedirector): Closed m_savedStdout descriptor.
1034 2014-08-18 Grzegorz Czajkowski <g.czajkowski@samsung.com>
1036 [EFL] ewk_init() is sufficient to initialize EFL components
1037 https://bugs.webkit.org/show_bug.cgi?id=136036
1039 Reviewed by Gyuyoung Kim.
1041 Developers do not have to initialize EFL components as ewk_init()
1044 * UIProcess/API/efl/ewk_intro.h:
1046 2014-08-16 Pratik Solanki <psolanki@apple.com>
1048 Rename DiskCacheMonitor to NetworkDiskCacheMonitor
1049 https://bugs.webkit.org/show_bug.cgi?id=135897
1051 Reviewed by Andreas Kling.
1053 In preparation for moving DiskCacheMonitor code to WebCore in bug 135896, rename the WebKit2
1054 class to NetworkDiskCacheMonitor.
1056 * NetworkProcess/mac/NetworkDiskCacheMonitor.h: Renamed from Source/WebKit2/NetworkProcess/mac/DiskCacheMonitor.h.
1057 (WebKit::NetworkDiskCacheMonitor::resourceRequest):
1058 * NetworkProcess/mac/NetworkDiskCacheMonitor.mm: Renamed from Source/WebKit2/NetworkProcess/mac/DiskCacheMonitor.mm.
1059 (WebKit::NetworkDiskCacheMonitor::monitorFileBackingStoreCreation):
1060 (WebKit::NetworkDiskCacheMonitor::NetworkDiskCacheMonitor):
1061 (WebKit::NetworkDiskCacheMonitor::messageSenderConnection):
1062 (WebKit::NetworkDiskCacheMonitor::messageSenderDestinationID):
1063 * NetworkProcess/mac/NetworkResourceLoaderMac.mm:
1064 (WebKit::NetworkResourceLoader::willCacheResponseAsync):
1065 * WebKit2.xcodeproj/project.pbxproj:
1067 2014-08-16 Byungseon Shin <sun.shin@lge.com>
1069 [GTK] build fails with error: cannot allocate an object of abstract type 'WebKit::PageClientImpl'
1070 https://bugs.webkit.org/show_bug.cgi?id=136017
1072 Reviewed by Gyuyoung Kim.
1074 * UIProcess/API/gtk/PageClientImpl.cpp:
1075 (WebKit::PageClientImpl::didFirstVisuallyNonEmptyLayoutForMainFrame):
1076 (WebKit::PageClientImpl::didFinishLoadForMainFrame):
1077 * UIProcess/API/gtk/PageClientImpl.h:
1079 2014-08-15 Ryuan Choi <ryuan.choi@samsung.com>
1081 [EFL] Add ewk_intro.h to describe main page of doxygen
1082 https://bugs.webkit.org/show_bug.cgi?id=136013
1084 Reviewed by Gyuyoung Kim.
1086 * PlatformEfl.cmake:
1087 * UIProcess/API/efl/EWebKit2.h.in:
1088 * UIProcess/API/efl/ewk_intro.h: Added.
1090 2014-08-15 Zalan Bujtas <zalan@apple.com>
1092 Do not use FloatRect::infiniteRect() to flag full repaints.
1093 https://bugs.webkit.org/show_bug.cgi?id=135900
1095 Reviewed by Simon Fraser.
1097 Converting FloatRect::infiniteRect() to IntRect leads to value overflow
1098 and we end up with invalid repaint rectangle. Use a boolean flag to indicate
1099 full repaint request.
1101 Covered by existing tests.
1103 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
1104 (WebKit::PlatformCALayerRemote::setNeedsDisplayInRect):
1105 (WebKit::PlatformCALayerRemote::setNeedsDisplay):
1106 * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
1107 * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.h:
1108 * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
1109 (WebKit::PlatformCALayerRemoteCustom::setNeedsDisplayInRect):
1110 (WebKit::PlatformCALayerRemoteCustom::setNeedsDisplay):
1111 * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp:
1112 (WebKit::PlatformCALayerRemoteTiledBacking::setNeedsDisplayInRect):
1113 (WebKit::PlatformCALayerRemoteTiledBacking::setNeedsDisplay):
1114 * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:
1116 2014-08-15 Alexey Proskuryakov <ap@apple.com>
1118 REGRESSION (r172660): WebKit2.TerminateTwice asserts
1119 https://bugs.webkit.org/show_bug.cgi?id=136012
1121 * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::terminateProcess):
1122 Added bug number to a fixme.
1124 2014-08-15 Ryuan Choi <ryuan.choi@samsung.com>
1126 Unreviewed build fix on the EFL port since r172635
1128 * UIProcess/WebPageProxy.cpp: Guard removeNavigationGestureSnapshot with PLATFORM(MAC) macro.
1129 * UIProcess/WebPageProxy.h: Ditto.
1130 * UIProcess/efl/WebViewEfl.h: Added didFirstVisuallyNonEmptyLayoutForMainFrame and didFinishLoadForMainFrame as dummy.
1132 2014-08-15 Alexey Proskuryakov <ap@apple.com>
1134 Improve page to process relationship tracking
1135 https://bugs.webkit.org/show_bug.cgi?id=135996
1136 <rdar://problem/16991213>
1138 Reviewed by Sam Weinig.
1140 * UIProcess/VisitedLinkProvider.cpp:
1141 (WebKit::VisitedLinkProvider::removeAll):
1142 (WebKit::VisitedLinkProvider::pendingVisitedLinksTimerFired):
1143 (WebKit::VisitedLinkProvider::sendTable):
1144 Added assertions for m_processes only having valid entries.
1146 * UIProcess/WebPageProxy.cpp:
1147 (WebKit::WebPageProxy::reattachToWebProcess): When attaching to a new process,
1148 tell the old process that the page is not longer associated with it, avoiding
1149 a potential stale pointer.
1150 If re-attached to an existing process, make sure that we perform all the same
1151 registrations as after having launched a new process. This substantially improves
1152 the behavior when the number of open tabs is over process limit.
1153 (WebKit::WebPageProxy::reattachToWebProcessWithItem): Added ASSERT(!isValid())
1154 to avoid confusion. All other calls to reattachToWebProcess() have this as a
1155 runtime check, but reattachToWebProcessWithItem() is only called for valid pages.
1156 (WebKit::WebPageProxy::terminateProcess): Added an assertion with a FIXME for
1157 something that will need to be fixed another day.
1159 * UIProcess/WebPageProxy.h: Removed an unimplemented function.
1161 * UIProcess/WebProcessProxy.cpp:
1162 (WebKit::WebProcessProxy::addExistingWebPage): Added assertions for page map sanity.
1163 (WebKit::WebProcessProxy::removeWebPage): Added a check for page state being Terminated
1164 already. This avoids an assertion failure that happened under the new call to
1165 removeWebPage() in reattachToWebProcess(), as we are now calling it for terminated
1166 processes that are not in WebContext::m_processes any more.
1167 (WebKit::WebProcessProxy::didFinishLaunching): Added an assertion that page agrees
1168 about using this process.
1170 2014-08-15 Gavin Barraclough <barraclough@apple.com>
1172 Fix plugin visibility check.
1173 https://bugs.webkit.org/show_bug.cgi?id=135991
1175 D'oh, more unreviewed typo fix. :-(
1177 * PluginProcess/PluginControllerProxy.cpp:
1178 (WebKit::PluginControllerProxy::visibilityDidChange):
1179 (WebKit::PluginControllerProxy::windowVisibilityChanged):
1180 (WebKit::PluginControllerProxy::updateVisibilityActivity):
1181 (WebKit::PluginControllerProxy::updateVisiblityActivity): Deleted.
1182 * PluginProcess/PluginControllerProxy.h:
1184 2014-08-15 Wenson Hsieh <wenson_hsieh@apple.com>
1186 Implement snapping behavior for iOS
1187 https://bugs.webkit.org/show_bug.cgi?id=135769
1189 Reviewed by Brent Fulgham.
1191 Added support for snap points on iOS.
1193 * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
1194 (ArgumentCoder<ScrollingStateScrollingNode>::encode): Added snap offset encoding.
1195 (ArgumentCoder<ScrollingStateScrollingNode>::decode): Added snap offset decoding.
1196 * UIProcess/API/Cocoa/WKWebView.mm:
1197 (-[WKWebView scrollViewWillEndDragging:withVelocity:targetContentOffset:]): For mainframe scrolling, retargets the scroll destination to the appropriate snap point.
1198 * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h: Added methods to extract relevant information for WKWebView from snap offsets in mainframe scrolling.
1199 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
1200 (-[WKOverflowScrollViewDelegate scrollViewWillEndDragging:withVelocity:targetContentOffset:]): For overflow scrolling, retargets the scroll destination to the appropriate snap point.
1201 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::updateAfterChildren): Sets the deceleration factor to FAST if snap points are active.
1202 * UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm:
1203 (WebKit::RemoteScrollingCoordinatorProxy::adjustTargetContentOffsetForSnapping): Used by WKWebView for mainframe scrolling to retarget the scroll destination, if necessary.
1204 (WebKit::RemoteScrollingCoordinatorProxy::shouldSetScrollViewDecelerationRateFast): Used by WKWebView for mainframe scrolling to determine whether to set deceleration rate to the fast value.
1205 (WebKit::RemoteScrollingCoordinatorProxy::shouldSnapForMainFrameScrolling): Helper method.
1206 (WebKit::RemoteScrollingCoordinatorProxy::closestSnapOffsetForMainFrameScrolling): Helper method.
1208 2014-08-15 Gavin Barraclough <barraclough@apple.com>
1210 Fix plugin visibility check.
1211 https://bugs.webkit.org/show_bug.cgi?id=135991
1213 Unreviewed typo fix.
1215 * PluginProcess/PluginControllerProxy.cpp:
1216 (WebKit::PluginControllerProxy::PluginControllerProxy):
1217 (WebKit::PluginControllerProxy::visibilityDidChange):
1218 (WebKit::PluginControllerProxy::windowVisibilityChanged):
1219 (WebKit::PluginControllerProxy::updateVisibilityActivity):
1220 * PluginProcess/PluginControllerProxy.h:
1222 2014-08-15 Gavin Barraclough <barraclough@apple.com>
1224 Fix plugin visibility check.
1225 https://bugs.webkit.org/show_bug.cgi?id=135991
1227 Reviewed by Andreas Kling.
1229 We should only take a UserActivity if the plugin is in a visible window,
1230 and also is itself visible.
1232 * PluginProcess/PluginControllerProxy.cpp:
1233 (WebKit::PluginControllerProxy::PluginControllerProxy):
1234 - initialize member state.
1235 (WebKit::PluginControllerProxy::visibilityDidChange):
1236 (WebKit::PluginControllerProxy::windowVisibilityChanged):
1237 - update member state & call updateVisibilityActivity.
1238 (WebKit::PluginControllerProxy::updateVisibilityActivity):
1239 - enable the UserActivity only if both visibilities are true.
1240 * PluginProcess/PluginControllerProxy.h:
1241 - added m_isVisible, m_isWindowVisible, updateVisibilityActivity.
1243 2014-08-15 Enrica Casucci <enrica@apple.com>
1245 [Services with UI] Selections are incorrect when selecting three lines.
1246 https://bugs.webkit.org/show_bug.cgi?id=135989
1247 <rdar://problem/18032571>
1249 Reviewed by Tim Horton.
1251 The stitching algorithm did not handle correctly the case of selections
1252 over three lines if the middle line is composed of only one rectangle.
1254 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1255 (WebKit::stitchRects):
1257 2014-08-15 Tim Horton <timothy_horton@apple.com>
1259 Service overlays stay fixed when <iframe> scrolls
1260 https://bugs.webkit.org/show_bug.cgi?id=135959
1261 <rdar://problem/17957716>
1263 Reviewed by Enrica Casucci.
1265 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1266 (WebKit::ServicesOverlayController::highlightsAreEquivalent):
1267 Tiny correctness fix; highlights can only be equivalent if their
1268 types are equivalent as well.
1270 2014-08-15 Gavin Barraclough <barraclough@apple.com>
1272 de-PLATFORM(COCOA) a couple of methods in plugin code
1273 https://bugs.webkit.org/show_bug.cgi?id=135987
1275 Reviewed by Sam Weinig.
1277 Pass through the visibility & focus on all platforms, to simplify & avoid
1278 any weird inconsistencies between platforms.
1280 * PluginProcess/PluginControllerProxy.cpp:
1281 (WebKit::PluginControllerProxy::windowFocusChanged):
1282 (WebKit::PluginControllerProxy::windowVisibilityChanged):
1283 * PluginProcess/PluginControllerProxy.h:
1284 * PluginProcess/PluginControllerProxy.messages.in:
1285 * PluginProcess/mac/PluginControllerProxyMac.mm:
1286 (WebKit::PluginControllerProxy::windowFocusChanged): Deleted.
1287 (WebKit::PluginControllerProxy::windowVisibilityChanged): Deleted.
1288 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1289 (WebKit::NetscapePlugin::windowFocusChanged):
1290 (WebKit::NetscapePlugin::windowVisibilityChanged):
1291 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1292 * WebProcess/Plugins/Plugin.h:
1293 * WebProcess/Plugins/PluginProxy.cpp:
1294 (WebKit::PluginProxy::windowAndViewFramesChanged):
1295 * WebProcess/Plugins/PluginProxy.h:
1296 * WebProcess/Plugins/PluginView.cpp:
1297 (WebKit::PluginView::viewStateDidChange):
1298 (WebKit::PluginView::platformViewStateDidChange): Deleted.
1299 * WebProcess/Plugins/PluginView.h:
1301 2014-08-15 Tim Horton <timothy_horton@apple.com>
1303 Service overlays stay fixed when <iframe> scrolls
1304 https://bugs.webkit.org/show_bug.cgi?id=135959
1305 <rdar://problem/17957716>
1307 Reviewed by Enrica Casucci.
1309 * WebProcess/WebPage/PageOverlay.cpp:
1310 (WebKit::PageOverlay::didScrollFrame):
1311 * WebProcess/WebPage/PageOverlay.h:
1312 (WebKit::PageOverlay::Client::didScrollFrame):
1313 * WebProcess/WebPage/PageOverlayController.cpp:
1314 (WebKit::PageOverlayController::didScrollFrame):
1315 Push didScrollFrame down to the overlays.
1317 * WebProcess/WebPage/ServicesOverlayController.h:
1318 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1319 (WebKit::ServicesOverlayController::Highlight::createForSelection):
1320 Hold on to the selection's Range so we can use it to compare Highlights later.
1322 (WebKit::ServicesOverlayController::Highlight::Highlight):
1323 (WebKit::ServicesOverlayController::Highlight::setDDHighlight):
1324 Factor the code to set up and paint the highlight out, so that we can
1325 set a new DDHighlightRef on a Highlight and the layer moves/reshapes/repaints.
1327 (WebKit::ServicesOverlayController::buildPhoneNumberHighlights):
1328 (WebKit::ServicesOverlayController::buildSelectionHighlight):
1329 (WebKit::ServicesOverlayController::replaceHighlightsOfTypePreservingEquivalentHighlights):
1330 Factor replaceHighlightsOfTypePreservingEquivalentHighlights out
1331 so that we can use it for buildSelectionHighlight as well.
1333 Steal the DDHighlightRef from the new Highlight when re-using an old one
1334 so that the newly computed rects are used instead of the old ones.
1336 (WebKit::ServicesOverlayController::highlightsAreEquivalent):
1337 We will always have a Range now, so we can always check equivalence using it.
1339 (WebKit::ServicesOverlayController::didScrollFrame):
1340 Rebuild all highlights upon subframe scroll, as they might have moved.
1341 We could optimize this in the future, but for now it's cheap enough
1342 and rare enough that it doesn't matter.
1344 2014-08-15 Tim Horton <timothy_horton@apple.com>
1346 REGRESSION (WebKit2 Gestures): White flash when swiping back to cnn.com's homepage from an article
1347 https://bugs.webkit.org/show_bug.cgi?id=135951
1348 <rdar://problem/18006149>
1350 Reviewed by Simon Fraser.
1352 Wait for (the first visually non-empty layout AND the render tree size threshold to be hit),
1353 OR didFinishLoadForFrame, whichever comes first. Once we've done the first visually non-empty layout,
1354 we'll start the watchdog and tear down the snapshot in three seconds no matter what.
1355 Also, force a repaint so we can asynchronously wait for the Web Process to paint and return to us
1356 before removing the snapshot, which improves our chances that something is actually on the screen.
1358 * UIProcess/API/mac/WKView.mm:
1359 (-[WKView _didFirstVisuallyNonEmptyLayoutForMainFrame]):
1360 (-[WKView _didFinishLoadForMainFrame]):
1361 (-[WKView _removeNavigationGestureSnapshot]):
1362 * UIProcess/API/mac/WKViewInternal.h:
1363 * UIProcess/PageClient.h:
1364 * UIProcess/WebPageProxy.cpp:
1365 (WebKit::WebPageProxy::didFinishLoadForFrame):
1366 (WebKit::WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame):
1367 (WebKit::WebPageProxy::removeNavigationGestureSnapshot):
1368 * UIProcess/WebPageProxy.h:
1369 * UIProcess/ios/PageClientImplIOS.h:
1370 * UIProcess/ios/PageClientImplIOS.mm:
1371 (WebKit::PageClientImpl::didFirstVisuallyNonEmptyLayoutForMainFrame):
1372 (WebKit::PageClientImpl::didFinishLoadForMainFrame):
1373 * UIProcess/mac/PageClientImpl.h:
1374 * UIProcess/mac/PageClientImpl.mm:
1375 (WebKit::PageClientImpl::didFirstVisuallyNonEmptyLayoutForMainFrame):
1376 (WebKit::PageClientImpl::didFinishLoadForMainFrame):
1377 (WebKit::PageClientImpl::removeNavigationGestureSnapshot):
1378 Plumb didFirstVisuallyNonEmptyLayoutForMainFrame and didFinishLoadForMainFrame
1379 through to ViewGestureController from WebPageProxy via the PageClient, etc.
1381 Ditto for removeNavigationGestureSnapshot, though it is called from a
1382 VoidCallback in ViewGestureController instead of from WebFrameLoaderClient and friends.
1384 * UIProcess/mac/ViewGestureController.h:
1385 * UIProcess/mac/ViewGestureControllerMac.mm:
1386 (WebKit::ViewGestureController::ViewGestureController):
1387 (WebKit::ViewGestureController::endSwipeGesture):
1388 When finishing a swipe, we want to wait for both the first visually non-empty layout
1389 and the render tree size threshold being hit.
1391 (WebKit::ViewGestureController::didHitRenderTreeSizeThreshold):
1392 (WebKit::ViewGestureController::didFirstVisuallyNonEmptyLayoutForMainFrame):
1393 When both of these things have happened, remove the swipe snapshot (after forcing a repaint).
1394 For didFirstVisuallyNonEmptyLayoutForMainFrame, we will also start a watchdog
1395 ensuring that we remove the snapshot in three seconds.
1397 (WebKit::ViewGestureController::didFinishLoadForMainFrame):
1398 When didFinishLoadForMainFrame happens, remove the swipe snapshot (after forcing a repaint).
1400 (WebKit::ViewGestureController::swipeSnapshotWatchdogTimerFired):
1401 If the watchdog timer fires, remove the swipe snapshot (after forcing a repaint).
1403 (WebKit::ViewGestureController::removeSwipeSnapshotAfterRepaint):
1404 Force a repaint and wait for the async callback before removing the snapshot.
1405 It is safe to hold on to the WebPageProxy here because it will always
1406 call all of its callbacks before it is destroyed.
1407 Avoid enqueuing multiple force-repaints.
1409 (WebKit::ViewGestureController::removeSwipeSnapshot):
1411 2014-08-15 Gavin Barraclough <barraclough@apple.com>
1413 Fix plugin visibility initialization
1414 https://bugs.webkit.org/show_bug.cgi?id=135985
1416 Reviewed by Geoffrey Garen.
1418 * WebProcess/Plugins/PluginView.cpp:
1419 (WebKit::PluginView::didInitializePlugin):
1420 - We're not currently initializing the plugin visibility state,
1421 and we're passing the wrong value for window visibility.
1423 2014-08-15 Gavin Barraclough <barraclough@apple.com>
1425 Simplify visibility activity accounting for plugins
1426 https://bugs.webkit.org/show_bug.cgi?id=135981
1428 Reviewed by Dan Bernstein.
1430 Just take one per connection, rather than implementing a counting mechanism.
1432 * PluginProcess/PluginControllerProxy.cpp:
1433 (WebKit::PluginControllerProxy::PluginControllerProxy):
1434 * PluginProcess/PluginControllerProxy.h:
1435 - added m_visiblityActivity.
1436 * PluginProcess/PluginProcess.cpp:
1437 (WebKit::PluginProcess::PluginProcess):
1438 (WebKit::PluginProcess::pluginsForWebProcessDidBecomeVisible): Deleted.
1439 (WebKit::PluginProcess::pluginsForWebProcessDidBecomeHidden): Deleted.
1440 * PluginProcess/PluginProcess.h:
1441 - removed pluginsForWebProcessDidBecomeVisible/Hidden.
1442 * PluginProcess/WebProcessConnection.cpp:
1443 (WebKit::WebProcessConnection::removePluginControllerProxy):
1444 (WebKit::WebProcessConnection::pluginDidBecomeVisible): Deleted.
1445 (WebKit::WebProcessConnection::pluginDidBecomeHidden): Deleted.
1446 * PluginProcess/WebProcessConnection.h:
1447 - removed pluginDidBecomeVisible/Hidden.
1448 * PluginProcess/mac/PluginControllerProxyMac.mm:
1449 (WebKit::PluginControllerProxy::windowVisibilityChanged):
1450 - windowVisibilityChanged uses m_visiblityActivity, rather than calling to PluginControllerProxy.
1452 2014-08-15 Carlos Garcia Campos <cgarcia@igalia.com>
1454 Unreviewed. Update OptionsGTK.cmake and NEWS for 2.5.3 release.
1456 * gtk/NEWS: Add release notes for 2.5.3.
1458 2014-08-14 Enrica Casucci <enrica@apple.com>
1460 [Services with UI] Selection services don't work inside <iframes>.
1461 https://bugs.webkit.org/show_bug.cgi?id=135941
1462 <rdar://problem/17957690>
1464 Reviewed by Tim Horton.
1466 Need to map the selection rectangles using the correct FrameView.
1467 When handling the click, we must use the selection from the focused frame.
1469 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1470 (WebKit::ServicesOverlayController::buildSelectionHighlight):
1471 (WebKit::ServicesOverlayController::handleClick):
1473 2014-08-13 Mark Rowe <mrowe@apple.com>
1475 <https://webkit.org/b/135909> Move helper applications out of the root of the framework.
1477 As described in <https://developer.apple.com/library/mac/technotes/tn2206/>, for bundles containing
1478 a Versions directory there may be no other content at the top level of the bundle other than symlinks.
1479 Upcoming changes to code signing will prevent bundles that violate this rule from being signed.
1481 Reviewed by Sam Weinig.
1483 * Configurations/Base.xcconfig: Define a configuration setting that points to the content directory
1484 of the framework. On OS X this is Versions/A. On iOS, where frameworks are shallow, this is the top level.
1485 * Configurations/BaseLegacyProcess.xcconfig: Install the legacy processes in the content directory
1487 * WebKit2.xcodeproj/project.pbxproj: Copy the legacy processes into the content directory of the
1488 framework during engineering builds. Generate symlinks for the legacy processes to their locations
1489 in Versions/Current. This is necessary because -[NSBundle pathForAuxiliaryExecutable:] only looks
1490 at the top level of the framework wrapper.
1492 2014-08-14 Michael Catanzaro <mcatanzaro@igalia.com>
1494 WebKit2GTK - WebKitWebProcess assertion fails when dragging and dropping a file into the view
1495 https://bugs.webkit.org/show_bug.cgi?id=127576
1497 Reviewed by Carlos Garcia Campos.
1499 * UIProcess/WebPageProxy.cpp:
1500 (WebKit::WebPageProxy::performDragControllerAction): Assume read access
1501 to any file that has been dragged into the web view when compiling for
1502 GTK, since we don't support sandbox extensions.
1504 2014-08-13 Wenson Hsieh <wenson_hsieh@apple.com>
1506 Enable CSS_SCROLL_SNAP for iOS
1507 https://bugs.webkit.org/show_bug.cgi?id=135915
1509 Turn on CSS_SCROLL_SNAP for iOS and the iOS simulator.
1511 Reviewed by Tim Horton.
1513 * Configurations/FeatureDefines.xcconfig:
1515 2014-08-13 Enrica Casucci <enrica@apple.com>
1517 [Services with UI] Use a longer delay duration for editable content.
1518 https://bugs.webkit.org/show_bug.cgi?id=135918
1519 <rdar://problem/17998929>
1521 Reviewed by Tim Horton.
1523 Use a 1 second delay for selections in editable content.
1525 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1526 (WebKit::ServicesOverlayController::remainingTimeUntilHighlightShouldBeShown):
1528 2014-08-13 Mark Rowe <mrowe@apple.com>
1530 <https://webkit.org/b/135911> WebKit should build on Yosemite with the public SDK.
1532 Reviewed by Darin Adler.
1534 * Platform/IPC/mac/ImportanceAssertion.h: Forward-declare the new assertion functions we use.
1535 * UIProcess/mac/WebContextMenuProxyMac.mm: Forward-declare some details related to NSSharingServicePicker.
1537 2014-08-13 Alexey Proskuryakov <ap@apple.com>
1541 * UIProcess/WebContext.cpp:
1542 (WebKit::WebContext::ensureNetworkProcess):
1543 (WebKit::WebContext::createNewWebProcess):
1545 2014-08-13 Joseph Pecoraro <pecoraro@apple.com>
1547 Opening Web Inspector causes a large amount of sandbox violations
1548 https://bugs.webkit.org/show_bug.cgi?id=135908
1550 Reviewed by Timothy Hatcher.
1552 * WebProcess/com.apple.WebProcess.sb.in:
1553 Permit the WebContent process to create file read extensions for the
1554 system WebInspectorUI.framework which the Network process can already
1557 2014-08-13 Tim Horton <timothy_horton@apple.com>
1559 Avoid making new active service overlay highlights while the mouse is down
1560 https://bugs.webkit.org/show_bug.cgi?id=135872
1561 <rdar://problem/17982341>
1563 Reviewed by Enrica Casucci.
1565 * WebProcess/WebPage/ServicesOverlayController.h:
1566 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1567 (WebKit::ServicesOverlayController::remainingTimeUntilHighlightShouldBeShown):
1568 (WebKit::ServicesOverlayController::mouseEvent):
1569 If the mouse is pressed or it's been less than 200ms since the mouse went up,
1570 don't allow the highlight to change. We apply the mouse-is-pressed rule to telephone
1571 number highlights as well, unlike the rest of the hysteresis logic.
1573 2014-08-13 Timothy Hatcher <timothy@apple.com>
1575 Web Inspector: Workaround a NSWindow change to the title bar.
1576 https://bugs.webkit.org/show_bug.cgi?id=135880
1578 Reviewed by Joseph Pecoraro.
1580 * UIProcess/mac/WebInspectorProxyMac.mm:
1581 (WebKit::WebInspectorProxy::createInspectorWindow): Set titlebarAppearsTransparent on 10.10.
1582 Only call border thickness APIs on 10.9 and earlier.
1583 (WebKit::WebInspectorProxy::platformCreateInspectorPage): Only call setDrawsBackground: on 10.9 and earlier.
1584 (WebKit::WebInspectorProxy::platformSetToolbarHeight): Only call setContentBorderThickness: on 10.9 and earlier.
1586 2014-08-13 Ryuan Choi <ryuan.choi@samsung.com>
1588 [EFL] Add API to set application name for the user agent
1589 https://bugs.webkit.org/show_bug.cgi?id=135640
1591 Reviewed by Gyuyoung Kim.
1593 Add ewk_application_name_for_user_agent_set to make default user agent string
1594 with application name which application passes.
1595 It's useful for application to set only application information without knowledge
1596 of legacy user agent components.
1598 * UIProcess/API/efl/EwkView.cpp:
1600 (EwkView::setApplicationNameForUserAgent):
1601 * UIProcess/API/efl/EwkView.h:
1602 (EwkView::applicationNameForUserAgent):
1603 * UIProcess/API/efl/ewk_view.cpp:
1604 (ewk_view_application_name_for_user_agent_set):
1605 (ewk_view_application_name_for_user_agent_get):
1606 * UIProcess/API/efl/ewk_view.h:
1607 * UIProcess/API/efl/tests/test_ewk2_view.cpp:
1609 * UIProcess/efl/WebPageProxyEfl.cpp:
1610 (WebKit::WebPageProxy::standardUserAgent):
1612 2014-08-12 Carlos Garcia Campos <cgarcia@igalia.com>
1614 [CMAKE] WebProcess shouldn't need to explicitly link to JavaScriptCore and WebCore
1615 https://bugs.webkit.org/show_bug.cgi?id=135832
1617 Reviewed by Gyuyoung Kim.
1619 Linking to WebKit2 should be enough, like Network and Plugin processes.
1623 2014-08-12 Tim Horton <timothy_horton@apple.com>
1625 Document-relative page overlays drop some mouse events with non-zero top content inset
1626 https://bugs.webkit.org/show_bug.cgi?id=135871
1627 <rdar://problem/17982275>
1629 Reviewed by Beth Dakin.
1631 * WebProcess/WebPage/PageOverlay.cpp:
1632 (WebKit::PageOverlay::mouseEvent):
1633 Convert the mouse position into document-relative coordinates; the bounds()
1634 already are! This way, we can actually compare them without being wrong sometimes.
1636 2014-08-12 Peyton Randolph <prandolph@apple.com>
1638 Runtime switch for long mouse press gesture. Part of 135257 - Add long mouse press gesture
1639 https://bugs.webkit.org/show_bug.cgi?id=135682
1641 Reviewed by Tim Horton.
1643 * Configurations/FeatureDefines.xcconfig: Remove LONG_MOUSE_PRESS feature flag.
1644 * Shared/WebPreferencesDefinitions.h:
1645 Add LongMousePressEnabled preference, initially false.
1646 * UIProcess/API/C/WKPreferences.cpp:
1647 (WKPreferencesSetLongMousePressEnabled): Added.
1648 (WKPreferencesGetLongMousePressEnabled): Added.
1649 * UIProcess/API/C/WKPreferencesRefPrivate.h:
1650 * WebProcess/WebPage/WebPage.cpp:
1651 (WebKit::WebPage::updatePreferences):
1652 Reflect the WebKit long mouse press setting in WebCore.
1654 2014-08-12 Pratik Solanki <psolanki@apple.com>
1656 Cached file backed resources don't make it to the Web Process when NETWORK_CFDATA_ARRAY_CALLBACK is enabled
1657 https://bugs.webkit.org/show_bug.cgi?id=135727
1658 <rdar://problem/17947880>
1660 Reviewed by Darin Adler.
1662 tryGetShareableHandleFromSharedBuffer() assumed that we have a file backed resource only if
1663 we had a CFDataRef (platformData()) in SharedBuffer. This is wrong when we use the data
1664 array callbacks since the file backed buffer could be in the data array. Instead of relying
1665 on hasPlatformData(), explicitly ask the SharedBuffer to give us a CFDataRef if it has one
1666 so that SharedBuffer can take care of the data array case.
1668 * NetworkProcess/mac/NetworkResourceLoaderMac.mm:
1669 (WebKit::NetworkResourceLoader::tryGetShareableHandleFromSharedBuffer):
1671 2014-08-12 Alexey Proskuryakov <ap@apple.com>
1673 REGRESSION: WebContent process has a sandbox extension for the entirety of user's temp directory
1674 https://bugs.webkit.org/show_bug.cgi?id=135853
1675 <rdar://problem/17986556>
1677 Reviewed by Oliver hunt.
1679 Move extensions recently added for iOS benefit under PLATFORM(IOS). Removed some
1680 dead code while at it (child processes don't need actual paths, they only need
1681 sandbox extensions in most cases).
1683 * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
1684 (WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
1685 * Shared/Network/NetworkProcessCreationParameters.cpp:
1686 (WebKit::NetworkProcessCreationParameters::encode):
1687 (WebKit::NetworkProcessCreationParameters::decode):
1688 * Shared/Network/NetworkProcessCreationParameters.h:
1689 * Shared/WebProcessCreationParameters.cpp:
1690 (WebKit::WebProcessCreationParameters::encode):
1691 (WebKit::WebProcessCreationParameters::decode):
1692 * Shared/WebProcessCreationParameters.h:
1693 * UIProcess/WebContext.cpp:
1694 (WebKit::WebContext::ensureNetworkProcess):
1695 (WebKit::WebContext::createNewWebProcess):
1696 (WebKit::WebContext::openGLCacheDirectory): Deleted.
1697 (WebKit::WebContext::networkingHSTSDatabasePath): Deleted.
1698 * UIProcess/WebContext.h:
1699 * UIProcess/efl/WebContextEfl.cpp:
1700 (WebKit::WebContext::containerTemporaryDirectory): Deleted.
1701 (WebKit::WebContext::platformDefaultNetworkingHSTSDatabasePath): Deleted.
1702 * UIProcess/gtk/WebContextGtk.cpp:
1703 (WebKit::WebContext::containerTemporaryDirectory): Deleted.
1704 (WebKit::WebContext::platformDefaultNetworkingHSTSDatabasePath): Deleted.
1705 * UIProcess/mac/WebContextMac.mm:
1706 (WebKit::WebContext::openGLCacheDirectory):
1707 (WebKit::WebContext::parentBundleDirectory):
1708 (WebKit::WebContext::networkingHSTSDatabasePath):
1709 (WebKit::WebContext::platformDefaultOpenGLCacheDirectory): Deleted.
1710 (WebKit::WebContext::platformDefaultNetworkingHSTSDatabasePath): Deleted.
1711 * WebProcess/cocoa/WebProcessCocoa.mm:
1712 (WebKit::WebProcess::platformInitializeWebProcess):
1714 2014-08-12 Tim Horton <timothy_horton@apple.com>
1716 Small region (~1px tall) where you get the selection button instead of the phone number overlay
1717 https://bugs.webkit.org/show_bug.cgi?id=135852
1718 <rdar://problem/17992795>
1720 Reviewed by Enrica Casucci.
1722 * WebProcess/WebPage/ServicesOverlayController.h:
1723 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1724 (WebKit::ServicesOverlayController::findTelephoneNumberHighlightContainingSelectionHighlight):
1725 (WebKit::ServicesOverlayController::determineActiveHighlight):
1726 If our new active highlight is a selection highlight that is completely contained
1727 by one of the phone number highlights, we'll make the phone number highlight active
1728 even if it's not hovered. This fixes the case where the selection highlight
1729 (a subset of a telephone number) is slightly taller than the telephone number
1730 highlight, and can be hovered without hovering the phone number highlight.
1732 2014-08-12 Tim Horton <timothy_horton@apple.com>
1734 REGRESSION (r172424): Extra menu header in combined telephone number menu when no phone paired
1735 https://bugs.webkit.org/show_bug.cgi?id=135854
1736 <rdar://problem/17996339>
1738 Reviewed by Enrica Casucci.
1740 * UIProcess/mac/WebContextMenuProxyMac.mm:
1741 (WebKit::WebContextMenuProxyMac::setupServicesMenu):
1742 Get all the menu items ahead of time, and only add the shared header
1743 if there are any telephone number menu items.
1745 2014-08-12 Enrica Casucci <enrica@apple.com>
1747 Crash at com.apple.WebKit.WebContent at com.apple.WebKit: WebKit::expandForGap
1748 https://bugs.webkit.org/show_bug.cgi?id=135859
1749 <rdar://problem/17994679>
1751 Reviewed by Tim Horton.
1753 expandForGap made the assumption that the selection rects were always three.
1754 This was not true even before http://trac.webkit.org/changeset/172395 but
1755 was more likely to happen after that change.
1757 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1758 (WebKit::expandForGap):
1760 2014-08-12 Tim Horton <timothy_horton@apple.com>
1762 Don't show the combined menu if there are no services available
1763 https://bugs.webkit.org/show_bug.cgi?id=135846
1764 <rdar://problem/17582099>
1766 Reviewed by Enrica Casucci.
1768 * WebProcess/WebPage/ServicesOverlayController.h:
1771 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1772 (WebKit::ServicesOverlayController::determineActiveHighlight):
1773 Don't allow a selection Highlight to become active if there is no
1774 service available to handle it. Previously we showed the combined menu
1775 with just phone numbers in it if any were detected.
1777 2014-08-12 Tim Horton <timothy_horton@apple.com>
1779 Add a fade transition to services highlights
1780 https://bugs.webkit.org/show_bug.cgi?id=135829
1781 <rdar://problem/17935736>
1783 Reviewed by Enrica Casucci.
1785 Add a smooth fade to highlight installation and uninstallation.
1786 To do so, we make each highlight paint into its own small layer.
1788 * WebProcess/WebPage/PageOverlay.cpp:
1789 (WebKit::PageOverlay::layer):
1790 * WebProcess/WebPage/PageOverlay.h:
1791 * WebProcess/WebPage/PageOverlayController.cpp:
1792 (WebKit::PageOverlayController::layerForOverlay):
1793 * WebProcess/WebPage/PageOverlayController.h:
1794 Expose the GraphicsLayer on PageOverlay.
1796 * WebProcess/WebPage/ServicesOverlayController.h:
1797 (WebKit::ServicesOverlayController::Highlight::layer):
1798 (WebKit::ServicesOverlayController::activeHighlight):
1799 (WebKit::ServicesOverlayController::webPage):
1800 (WebKit::ServicesOverlayController::Highlight::Highlight): Deleted.
1802 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
1803 (WebKit::ServicesOverlayController::Highlight::createForSelection):
1804 (WebKit::ServicesOverlayController::Highlight::createForTelephoneNumber):
1805 (WebKit::ServicesOverlayController::Highlight::Highlight):
1806 Highlights now own a GraphicsLayer, which are later installed
1807 as sublayers of the ServicesOverlayController's PageOverlay layer.
1808 These layers are sized and positioned according to the DDHighlight's bounds.
1810 (WebKit::ServicesOverlayController::Highlight::~Highlight):
1811 (WebKit::ServicesOverlayController::Highlight::invalidate):
1812 ServicesOverlayController will invalidate any remaining highlights
1813 when it is torn down, so they can clear their backpointers.
1815 (WebKit::ServicesOverlayController::Highlight::notifyFlushRequired):
1816 Forward flush notifications to the DrawingArea.
1818 (WebKit::ServicesOverlayController::Highlight::paintContents):
1819 Paint the DDHighlight into the layer. Translation is done by the layer position,
1820 so we zero the bounds origin when painting.
1822 (WebKit::ServicesOverlayController::Highlight::deviceScaleFactor):
1823 Forward the deviceScaleFactor so that things are painted at the right scale.
1825 (WebKit::ServicesOverlayController::Highlight::fadeIn):
1826 (WebKit::ServicesOverlayController::Highlight::fadeOut):
1827 Apply a fade animation to the layer.
1829 (WebKit::ServicesOverlayController::Highlight::didFinishFadeOutAnimation):
1830 When the fade completes, unparent the layer, unless it has become active again.
1832 (WebKit::ServicesOverlayController::ServicesOverlayController):
1833 (WebKit::ServicesOverlayController::~ServicesOverlayController):
1834 Invalidate all highlights, so they can clear their backpointers.
1836 (WebKit::ServicesOverlayController::remainingTimeUntilHighlightShouldBeShown):
1837 Make remainingTimeUntilHighlightShouldBeShown act upon a particular highlight
1838 instead of always the active highlight.
1840 (WebKit::ServicesOverlayController::determineActiveHighlightTimerFired): Rename.
1842 (WebKit::ServicesOverlayController::drawRect):
1843 drawRect is no longer called and will no longer do anything; all of the
1844 painting is done in sublayers.
1846 (WebKit::ServicesOverlayController::buildPhoneNumberHighlights):
1847 Ensure that phone number Highlights stay stable even while the selection
1848 changes, by comparing the underlying Ranges and keeping around old Highlights
1849 that match the new ones. This enables us to e.g. fade in while changing
1850 the selection within a phone number.
1852 (WebKit::ServicesOverlayController::buildSelectionHighlight):
1853 (WebKit::ServicesOverlayController::didRebuildPotentialHighlights):
1854 (WebKit::ServicesOverlayController::createOverlayIfNeeded):
1855 Don't call setNeedsDisplay; the overlay doesn't have backing store.
1856 Instead, call determineActiveHighlight, which will install/uninstall
1857 highlights as necessary.
1859 (WebKit::ServicesOverlayController::determineActiveHighlight):
1860 Apply fade in/fade out to the overlays.
1861 Keep track of which highlight we're going to activate, until the hysteresis
1862 delay is up, then actually make it active/parent it/fade it in.
1863 We now will have no active highlight between the fade out of the previous one
1864 and the fade in of the new one (during the hysteresis delay).
1866 (WebKit::ServicesOverlayController::mouseEvent):
1867 The overlay now will not become active until the delay is up, so we don't
1868 need to check it again here.
1870 (WebKit::ServicesOverlayController::handleClick):
1871 (WebKit::ServicesOverlayController::didCreateHighlight):
1872 (WebKit::ServicesOverlayController::willDestroyHighlight):
1873 (WebKit::ServicesOverlayController::repaintHighlightTimerFired): Deleted.
1874 (WebKit::ServicesOverlayController::drawHighlight): Deleted.
1876 2014-08-11 Andy Estes <aestes@apple.com>
1878 [iOS] Get rid of iOS.xcconfig
1879 https://bugs.webkit.org/show_bug.cgi?id=135809
1881 Reviewed by Joseph Pecoraro.
1883 All iOS.xcconfig did was include AspenFamily.xcconfig, so there's no need for the indirection.
1885 * Configurations/Base.xcconfig:
1886 * Configurations/iOS.xcconfig: Removed.
1887 * WebKit2.xcodeproj/project.pbxproj:
1889 2014-08-12 Grzegorz Czajkowski <g.czajkowski@samsung.com>
1891 [EFL] Rename ewk_private.h to EwkDebug.h
1892 https://bugs.webkit.org/show_bug.cgi?id=135797
1894 Reviewed by Gyuyoung Kim.
1896 ewk_private.h contains only debug macros alllowing
1899 * UIProcess/API/efl/EwkView.cpp:
1900 * UIProcess/API/efl/ewk_main.cpp:
1901 * UIProcess/efl/EwkDebug.h: Renamed from Source/WebKit2/UIProcess/API/efl/ewk_private.h.
1902 * UIProcess/efl/ViewClientEfl.cpp:
1904 2014-08-12 Carlos Garcia Campos <cgarcia@igalia.com>
1906 [GTK] The plugins metadata cache doesn't work if the user cache directory doesn't exist
1907 https://bugs.webkit.org/show_bug.cgi?id=135834
1909 Reviewed by Philippe Normand.
1911 Make sure the user cache directory exists. If creating the
1912 directory fails for whatever reason, do not try to save the cache
1915 * UIProcess/Plugins/gtk/PluginInfoCache.cpp:
1916 (WebKit::PluginInfoCache::PluginInfoCache):
1917 (WebKit::PluginInfoCache::updatePluginInfo):
1919 2014-08-12 Alexey Proskuryakov <ap@apple.com>
1921 [Mac] Allow reading CoreGraphics debugging preferences
1922 https://bugs.webkit.org/show_bug.cgi?id=135821
1923 <rdar://problem/11219259>
1925 Reviewed by Darin Adler.
1927 * WebProcess/com.apple.WebProcess.sb.in:
1929 2014-08-11 Grzegorz Czajkowski <g.czajkowski@samsung.com>
1931 [EFL] Prevent the client from creating ewk_view when EWebkit is not initialized
1932 https://bugs.webkit.org/show_bug.cgi?id=135606
1934 Reviewed by Gyuyoung Kim.
1936 Similarly to EFL modules (eina, evas etc.), application using EWebKit
1937 has to initialize it using ewk_init().
1939 Do not allow the client to create ewk_view if ewk_init has not been called.
1940 Add an appropriate logs warning the client about wrong APIs usage.
1942 * UIProcess/API/efl/ewk_main.cpp: Add EwkMain class to control ewk lifetime.
1943 (WebKit::EwkMain::EwkMain):
1944 (WebKit::EwkMain::shared):
1945 (WebKit::EwkMain::~EwkMain): Add logs when the client forgot to destroy EWebkit.
1946 (WebKit::EwkMain::initialize):
1947 (WebKit::EwkMain::finalize):
1948 (WebKit::EwkMain::shutdownInitializedEFLModules):
1951 * UIProcess/API/efl/ewk_main_private.h: Added.
1952 (WebKit::EwkMain::isInitialized):
1953 (WebKit::EwkMain::logDomainId):
1954 * UIProcess/API/efl/ewk_private.h:
1955 * UIProcess/API/efl/ewk_view.cpp:
1957 Prevent the client from creating ewk_view when ewk_init() has not been called.
1959 2014-08-11 Enrica Casucci <enrica@apple.com>
1961 Improve look and feel of combined service menu..
1962 https://bugs.webkit.org/show_bug.cgi?id=135824
1963 <rdar://problem/17936880>
1965 Reviewed by Tim Horton.
1967 When showing the combined menu, list the phone numbers first,
1968 grouped under a common header, followed by the entries relative
1971 * Platform/mac/MenuUtilities.h:
1972 * Platform/mac/MenuUtilities.mm:
1973 (WebKit::menuItemTitleForTelephoneNumberGroup):
1974 (WebKit::menuItemForTelephoneNumber):
1975 * UIProcess/mac/WebContextMenuProxyMac.mm:
1976 (WebKit::WebContextMenuProxyMac::setupServicesMenu):
1978 2014-08-11 Joseph Pecoraro <pecoraro@apple.com>
1980 Add Private WKPreferences API for developer extras (show inspector)
1981 https://bugs.webkit.org/show_bug.cgi?id=135811
1983 Reviewed by Timothy Hatcher.
1985 * UIProcess/API/Cocoa/WKPreferences.mm:
1986 (-[WKPreferences _developerExtrasEnabled]):
1987 (-[WKPreferences _setDeveloperExtrasEnabled:]):
1988 * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
1990 2014-08-08 Enrica Casucci <enrica@apple.com>
1992 [Services with UI] Action menu arrow hit testing is sometimes wrong.
1993 https://bugs.webkit.org/show_bug.cgi?id=135776
1994 <rdar://problem/17837670>
1996 Reviewed by Brady Eidson.
1998 There was a problem in the algorithm that stitches together the selection rectangles
1999 to be given to Data Detectors API.
2000 This change adds a new function that stiches together all the rects contributing to the
2001 first line, all the rects contributing to the last line and all the ones in the middle.
2002 This way we can have a maximum of 3 non overlapping rectangles.
2004 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2005 (WebKit::stitchRects):
2006 (WebKit::compactRectsWithGapRects):
2008 2014-08-11 Gyuyoung Kim <gyuyoung.kim@samsung.com>
2010 Unreviewed, EFL build fix since r172385.
2012 * PlatformEfl.cmake:
2014 2014-08-11 Carlos Garcia Campos <cgarcia@igalia.com>
2016 Unreviewed. Update OptionsGTK.cmake and NEWS for 2.5.2 release.
2018 * gtk/NEWS: Add release notes for 2.5.2.
2020 2014-08-10 Carlos Garcia Campos <cgarcia@igalia.com>
2022 [GTK] No IPC messages are sent when building WebKitGTK+ with VERSION_SCRIPT
2023 https://bugs.webkit.org/show_bug.cgi?id=135760
2025 Reviewed by Philippe Normand.
2027 The problem is that the threading initialization is failing
2028 because there are two copies of WTF, one in libjavascriptcoregtk
2029 and the other in libwebkit2gtk. When WebKit2 is initialized in the
2030 UI process, JSC::initializeThreading() is called first and then
2031 WTF::initializeMainThread(). The former is calling
2032 ThreadIdentifierData::initializeOnce() initializing the
2033 ThreadIdentifierData::m_key symbol in libjavascriptcoregtk, while
2034 the latter is using the ThreadIdentifierData API from libwebkit2gtk
2035 that hasn't been initialized.
2037 * CMakeLists.txt: Do not add WTF to the list of WebKit2 libraries,
2038 WebKit2 already depends on JavaScriptCore that already links to WTF.
2040 2014-08-10 Tim Horton <timothy_horton@apple.com>
2042 Yelp phone number highlights often disappear
2043 https://bugs.webkit.org/show_bug.cgi?id=135789
2044 <rdar://problem/17971057>
2046 Reviewed by Brady Eidson.
2048 Since selectedTelephoneNumberRangesChanged doesn't provide an associated
2049 Frame, an incoming selectedTelephoneNumberRangesChanged from a subframe
2050 would overwrite ServicesOverlayController's cached (and potentially active)
2051 telephone number highlights.
2053 This happens a lot on Yelp, because they have many subframes which are
2054 doing layout on a regular basis.
2056 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2057 (WebKit::WebEditorClient::selectedTelephoneNumberRangesChanged):
2058 * WebProcess/WebCoreSupport/WebEditorClient.h:
2059 Adjust to the new (lack of) arguments.
2061 * WebProcess/WebPage/ServicesOverlayController.h:
2062 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2063 (WebKit::ServicesOverlayController::selectedTelephoneNumberRangesChanged):
2064 Adjust logging; we can revisit it later.
2066 (WebKit::ServicesOverlayController::buildPhoneNumberHighlights):
2067 When building phone number highlights, walk the Frame tree and retrieve
2068 them from all of the Editors.
2070 (WebKit::ServicesOverlayController::didRebuildPotentialHighlights):
2071 (WebKit::ServicesOverlayController::telephoneNumberRangesForFocusedFrame):
2072 (WebKit::ServicesOverlayController::determineActiveHighlight):
2073 (WebKit::ServicesOverlayController::handleClick):
2074 Retrieve the detected telephone number ranges from the focused frame
2075 when combining telephone numbers with selection services.
2076 This ensures that we don't show combined phone number highlights from other frames.
2078 2014-08-10 Tim Horton <timothy_horton@apple.com>
2080 Refactor ServiceOverlayController in preparation for fading between highlights
2081 https://bugs.webkit.org/show_bug.cgi?id=135787
2082 <rdar://problem/17935736>
2084 Reviewed by Brady Eidson.
2086 Rework ServicesOverlayController so that we always keep a set of generic
2087 "potential highlights", which are refcounted Highlight objects and
2088 wrap a DDHighlightRef, as well as a type (Selection or TelephoneNumber),
2089 Range (only used in the case of TelephoneNumber), and potentially more
2090 things in the future (like, say, fade state!).
2092 We eagerly update the list of potential highlights when the selection or set
2093 of detected telephone numbers changes, and use this information to install
2094 or uninstall the page overlay as needed.
2096 When we need to recompute the "active" highlight from this set (for example,
2097 we need to handle a mouse event or paint the highlight), we look through
2098 the set of potential highlights and decide. This moves the "active" highlight
2099 decision logic into one small and confined place.
2101 * WebProcess/WebPage/ServicesOverlayController.h:
2102 (WebKit::ServicesOverlayController::Highlight):
2103 Add the new aforementioned refcounted Highlight class.
2104 Rename m_lastHoveredHighlightChangeTime to m_lastActiveHighlightChangeTime.
2105 Make m_webPage a reference.
2106 The rest is just added/removed/adjusted functions for the refactoring.
2108 (WebKit::TelephoneNumberData::TelephoneNumberData): Deleted.
2109 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2110 (WebKit::ServicesOverlayController::Highlight::createForSelection):
2111 (WebKit::ServicesOverlayController::Highlight::createForTelephoneNumber):
2112 Create Highlights for the two different highlight types.
2114 (WebKit::ServicesOverlayController::ServicesOverlayController):
2115 (WebKit::ServicesOverlayController::willMoveToWebPage):
2116 Our WebPage pointer is always valid because it owns us; don't clear it.
2117 We need to keep it around so that we can uninstall the overlay and
2118 install it again later, anyway.
2120 (WebKit::ServicesOverlayController::selectionRectsDidChange):
2121 (WebKit::ServicesOverlayController::selectedTelephoneNumberRangesChanged):
2122 When selection rects or detected telephone numbers change, rebuild potential highlights.
2123 This will have the side-effect of installing the overlay if needed.
2125 (WebKit::ServicesOverlayController::mouseIsOverHighlight):
2126 Make this function take a Highlight instead of a DDHighlightRef.
2128 (WebKit::ServicesOverlayController::remainingTimeUntilHighlightShouldBeShown):
2129 Make this function take a Highlight instead of a DDHighlightRef.
2131 (WebKit::ServicesOverlayController::drawHighlight):
2132 Make this function take a Highlight instead of a DDHighlightRef.
2133 There's no reason to do the translation separately from the layer blit,
2134 also allowing us to avoid the StateSaver.
2136 (WebKit::ServicesOverlayController::drawRect):
2137 drawRect now always paints the active highlight, instead of duplicating
2138 logic about which highlight should be active.
2139 Also, it will update the active highlight before painting.
2140 We no longer need to re-determine whether the active highlight's phone
2141 number range is still a valid phone number range, because we rebuild
2142 the potential highlights whenever the set of phone number ranges changes.
2144 (WebKit::ServicesOverlayController::clearActiveHighlight):
2145 Mostly an adoption of new names.
2147 (WebKit::ServicesOverlayController::removeAllPotentialHighlightsOfType):
2148 Run through the list of potential highlights and remove any of the given type.
2149 The two highlight building functions use this helper to clear the old ones before building.
2151 (WebKit::ServicesOverlayController::buildPhoneNumberHighlights):
2152 (WebKit::ServicesOverlayController::buildSelectionHighlight):
2153 Rebuild the list of potential highlights, replacing all highlights of
2154 the given type with new ones.
2156 (WebKit::ServicesOverlayController::hasRelevantSelectionServices):
2157 Factor out the code that decides whether our current selection is
2158 viable for servicing based on whether we have plain-text and/or rich-text services.
2160 (WebKit::ServicesOverlayController::didRebuildPotentialHighlights):
2161 When rebuilding potential highlights, if we have no potential highlights at all,
2162 uninstall the page overlay; we don't need mouse tracking and don't need to
2163 paint anything. This improves memory use and compositing performance significantly,
2164 where previously we were leaving the overlay up forever after creating it.
2166 If we have either detected telephone numbers or relevant selection services,
2167 create and install the overlay if it doesn't already exist.
2169 (WebKit::ServicesOverlayController::createOverlayIfNeeded):
2170 This just moved from elsehwere, except that it now uses FadeMode::DoNotFade.
2171 It doesn't make sense to fade on install/uninstall (which happens even before hover)
2172 but not on changing the active highlight; fading will be re-addressed in the next patch.
2174 (WebKit::ServicesOverlayController::highlightsAreEquivalent):
2175 Determine whether two highlights are equivalent. While we may have
2176 created a new Highlight at rebuild time, if two telephone number
2177 highlights have equivalent ranges, there's no need to 'transition' to the new one.
2179 (WebKit::ServicesOverlayController::determineActiveHighlight):
2180 Run through the list of services, and try to find one that is hovered.
2181 We prefer telephone number highlights to selection highlights, and
2182 we will never make a selection highlight active if it is both
2183 not serviceable and there are no telephone numbers to show in the combined menu.
2184 This is the centralized location for determination of which highlight
2185 should be considered active. If the active highlight changed, update
2186 the time since last change and cancel the mouse-down tracking.
2188 (WebKit::ServicesOverlayController::mouseEvent):
2189 Adjust some comments to be more explanatory.
2190 A bunch of code moved out of here and into determineActiveHighlight.
2192 (WebKit::ServicesOverlayController::handleClick):
2193 Adjust to take a reference and use Highlight instead of DDHighlightRef.
2195 2014-08-10 Timothy Hatcher <timothy@apple.com>
2197 Web Inspector: new glyphs are visible on OS X 10.9 builds
2198 https://bugs.webkit.org/show_bug.cgi?id=135743
2200 Reviewed by Joseph Pecoraro.
2202 * UIProcess/mac/WebInspectorProxyMac.mm:
2203 (WebKit::WebInspectorProxy::createInspectorWindow): Use 10100 instead of 1090 for the version.
2205 2014-08-10 Carlos Garcia Campos <cgarcia@igalia.com>
2207 [GTK] REGRESSION(r166239): The ld version script is not being used
2208 https://bugs.webkit.org/show_bug.cgi?id=135694
2210 Reviewed by Martin Robinson.
2212 * CMakeLists.txt: Add VERSION_SCRIPT to WebKit2 link flags if present.
2214 2014-08-09 Tim Horton <timothy_horton@apple.com>
2216 REGRESSION (r172301): Combined phone number highlight doesn't appear if rich content is selected and we have no rich content services
2217 https://bugs.webkit.org/show_bug.cgi?id=135785
2218 <rdar://problem/17969843>
2220 Reviewed by Brady Eidson.
2222 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2223 (WebKit::ServicesOverlayController::drawSelectionHighlight):
2224 We can't early return in the rich-content-but-no-rich-services case
2225 if we have telephone numbers in the selection, because we want to offer
2226 them up in the combined menu.
2228 * UIProcess/mac/WebContextMenuProxyMac.mm:
2229 If we end up with no menu, because there were no services available,
2230 make a fresh one that we can fill with combined telephone number items.
2232 2014-08-08 Grzegorz Czajkowski <g.czajkowski@samsung.com>
2234 [EFL] Do not initialize g_type in WebProcessMain::platformInitialize()
2235 https://bugs.webkit.org/show_bug.cgi?id=135700
2237 Reviewed by Gyuyoung Kim.
2239 Inspired by r171788.
2240 Glib since 2.36 itself initializes g_type_init.
2242 * WebProcess/efl/WebProcessMainEfl.cpp:
2244 2014-08-08 Tim Horton <timothy_horton@apple.com>
2246 Build fix for 32-bit.
2248 * UIProcess/mac/ServicesController.mm:
2249 (WebKit::ServicesController::ServicesController):
2250 Don't dynamically refresh services in 32-bit apps. It's not possible
2251 to write a 32-bit app with the Modern API, so this doesn't matter.
2253 2014-08-08 Tim Horton <timothy_horton@apple.com>
2255 [mac] Dynamically update serviceability when the set of services changes
2256 https://bugs.webkit.org/show_bug.cgi?id=135738
2257 <rdar://problem/17533459>
2259 Reviewed by Brady Eidson.
2261 * UIProcess/WebContext.cpp:
2262 (WebKit::WebContext::createNewWebProcess):
2263 Adopt the new universal refreshExistingServices.
2265 (WebKit::WebContext::refreshExistingServices): Deleted.
2266 * UIProcess/WebContext.h:
2267 Remove WebContext::refreshExistingServices; there's no need for it.
2269 * UIProcess/mac/ServicesController.h:
2270 * UIProcess/mac/ServicesController.mm:
2271 Fix the build with only public headers by including NSSharingService.h itself.
2272 Place the NSSharingServicePicker (Details) category outside the #ifdef.
2273 Forward-declare and possibly import NSExtension SPI.
2275 (WebKit::ServicesController::ServicesController):
2276 Register a callback to be notified whenever the set of services changes.
2277 When this occurs, call refreshExistingServices. We let refreshExistingServices
2278 coalesce updates because these notifications can come in small batches.
2280 (WebKit::ServicesController::refreshExistingServices):
2281 Dispatch changes in service availability to all processes in all contexts.
2283 * UIProcess/mac/WebContextMenuProxyMac.mm:
2284 (WebKit::WebContextMenuProxyMac::setupServicesMenu):
2285 Adjust the referenced rdar:// and call ServicesController::refreshExistingServices
2286 instead of the now-removed WebContext:: variant. We can't remove this
2287 yet because our services state can still be stale because NSServiceSharingPicker
2288 can still sometimes lie about the current service state immediately after a change occurs;
2289 once that is fixed, we should get rid of this as well as the refresh in Web Process creation.
2291 2014-08-08 Timothy Horton <timothy_horton@apple.com>
2293 Clients that request the selection services menu after WebKit2 will get one with different metrics than otherwise
2294 https://bugs.webkit.org/show_bug.cgi?id=135765
2295 <rdar://problem/17962180>
2297 Reviewed by Brady Eidson.
2299 * UIProcess/mac/WebContextMenuProxyMac.mm:
2300 (WebKit::WebContextMenuProxyMac::setupServicesMenu):
2301 The menu is cached between clients, but we make adjustments to it.
2302 We should copy it before adjusting.
2304 2014-08-08 Timothy Horton <timothy_horton@apple.com>
2306 Services overlay dropdown is often in the wrong place with zoomed pages or horizontal scrolling
2307 https://bugs.webkit.org/show_bug.cgi?id=135755
2308 <rdar://problem/17907752>
2310 Reviewed by Brady Eidson.
2312 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2313 (WebKit::ServicesOverlayController::establishHoveredTelephoneHighlight):
2314 (WebKit::ServicesOverlayController::maybeCreateSelectionHighlight):
2315 DDHighlightCreateWithRectsInVisibleRectWithStyleAndDirection adjusts the
2316 location of the button based on the visible rect, trying to keep the button visible.
2318 We're handing it the wrong visible rect, though, not taking scrolling into account.
2320 This leads to pages that scroll horizontally showing the button on the left
2321 even if there's space for it on the right, or sometimes not showing it at all.
2323 Instead, provide the actual main FrameView visible rect; the same coordinate
2324 space that the highlight rects are provided in.
2326 2014-08-08 Timothy Horton <timothy_horton@apple.com>
2328 Additional items added to selection services menus are misaligned
2329 https://bugs.webkit.org/show_bug.cgi?id=135747
2330 <rdar://problem/17933167>
2332 Reviewed by Brady Eidson.
2334 * UIProcess/mac/WebContextMenuProxyMac.mm:
2335 (WebKit::WebContextMenuProxyMac::setupServicesMenu):
2336 Use NSSharingServicePickerStyleRollover for the rollover image services menu;
2337 use NSSharingServicePickerStyleTextSelection for the selection services menu.
2339 Set NSMenu's showsStateColumn to YES for selection services menus, so that
2340 other items added to the menu line up correctly.
2342 Remove an unncessary .get()
2344 2014-08-08 Grzegorz Czajkowski <g.czajkowski@samsung.com>
2346 [EFL] Remove unnecessary ewk_private.h includes
2347 https://bugs.webkit.org/show_bug.cgi?id=135753
2349 Reviewed by Gyuyoung Kim.
2351 Neither the below file uses the functionality from ewk_private.h.
2353 * UIProcess/API/efl/ewk_context.cpp:
2354 * UIProcess/API/efl/ewk_context_menu_item.cpp:
2355 * UIProcess/API/efl/ewk_cookie_manager.cpp:
2356 * UIProcess/API/efl/ewk_navigation_policy_decision.cpp:
2357 * UIProcess/API/efl/ewk_popup_menu_item.cpp:
2358 * UIProcess/API/efl/ewk_view.cpp:
2360 2014-08-08 Carlos Garcia Campos <cgarcia@igalia.com>
2362 [GTK] Do not use GtkWindow:resize-grip-visible with recent GTK+ versions
2363 https://bugs.webkit.org/show_bug.cgi?id=135699
2365 Reviewed by Philippe Normand.
2367 Resize grips support have been removed from GTK+ since 3.13.4, the
2368 API has been deprecated and does nothing.
2370 * UIProcess/API/gtk/WebKitWebViewBase.cpp:
2371 (webkitWebViewBaseSetToplevelOnScreenWindow):
2372 (resizeWebKitWebViewBaseFromAllocation):
2374 2014-08-07 Tim Horton <timothy_horton@apple.com>
2376 [Services with UI] Action menu does not appear if selection includes both text and an image
2377 https://bugs.webkit.org/show_bug.cgi?id=135731
2378 <rdar://problem/17837491>
2380 Reviewed by Dean Jackson.
2382 * UIProcess/WebContext.cpp:
2383 (WebKit::WebContext::createNewWebProcess):
2384 Initialize hasRichContentServices with the cached value.
2386 2014-08-07 Benjamin Poulain <bpoulain@apple.com>
2388 Get rid of SCRIPTED_SPEECH
2389 https://bugs.webkit.org/show_bug.cgi?id=135729
2391 Reviewed by Brent Fulgham.
2393 * Configurations/FeatureDefines.xcconfig:
2395 2014-08-07 Timothy Horton <timothy_horton@apple.com>
2397 setCustomSwipeViews inside didChangeBackForwardList client callback is ignored
2398 https://bugs.webkit.org/show_bug.cgi?id=135633
2399 <rdar://problem/17926507>
2401 Reviewed by Sam Weinig.
2403 * UIProcess/PageClient.h:
2404 * UIProcess/WebPageProxy.cpp:
2405 (WebKit::WebPageProxy::didChangeBackForwardList):
2406 * UIProcess/ios/PageClientImplIOS.h:
2407 * UIProcess/ios/PageClientImplIOS.mm:
2408 (WebKit::PageClientImpl::clearCustomSwipeViews): Deleted.
2409 * UIProcess/mac/PageClientImpl.h:
2410 * UIProcess/mac/PageClientImpl.mm:
2411 (WebKit::PageClientImpl::clearCustomSwipeViews): Deleted.
2412 WebKit clears the set of custom swipe views at the end of WebPageProxy::didChangeBackForwardList,
2413 *after* calling into the client. This means that if the client wants to setCustomSwipeViews in
2414 didChangeBackForwardList, it won't be respected.
2416 Since there's only one client of this SPI, let's just stop clearing the list of custom swipe
2417 views in WebKit and leave that totally up to the client.
2419 2014-08-07 Enrica Casucci <enrica@apple.com>
2421 [Services with UI] Action menu does not appear if selection includes both text and an image.
2422 https://bugs.webkit.org/show_bug.cgi?id=135731
2423 <rdar://problem/17837491>
2425 Reviewed by Brady Eidson.
2427 Adding a new setting to ServicesController to communicate to the WebProcess if
2428 there are services installed that can handle a combination of text and images.
2429 This way ServicesOverlayController can decide if it appropriate to show the hightlight
2430 based on the type of selection (text only or non text only). This information is retrieved
2431 when the selection rects are collected by SelectionGatherer and used by
2432 SelectionGatherer::Notifier to communicate the selection change.
2434 * Shared/WebProcessCreationParameters.cpp:
2435 (WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
2436 * Shared/WebProcessCreationParameters.h:
2437 * UIProcess/mac/ServicesController.h:
2438 (WebKit::ServicesController::hasRichContentServices):
2439 * UIProcess/mac/ServicesController.mm:
2440 (WebKit::ServicesController::ServicesController):
2441 (WebKit::ServicesController::refreshExistingServices):
2442 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2443 (WebKit::WebEditorClient::selectionRectsDidChange):
2444 * WebProcess/WebCoreSupport/WebEditorClient.h:
2445 * WebProcess/WebPage/ServicesOverlayController.h:
2446 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2447 (WebKit::ServicesOverlayController::ServicesOverlayController):
2448 (WebKit::ServicesOverlayController::selectionRectsDidChange):
2449 (WebKit::ServicesOverlayController::drawSelectionHighlight):
2450 * WebProcess/WebProcess.cpp:
2451 (WebKit::WebProcess::WebProcess):
2452 (WebKit::WebProcess::initializeWebProcess):
2453 (WebKit::WebProcess::setEnabledServices):
2454 * WebProcess/WebProcess.h:
2455 (WebKit::WebProcess::hasRichContentServices):
2456 * WebProcess/WebProcess.messages.in:
2458 2014-08-07 Ryuan Choi <ryuan.choi@samsung.com>
2460 [EFL] Fix several warnings of doxygen
2461 https://bugs.webkit.org/show_bug.cgi?id=135643
2463 Reviewed by Gyuyoung Kim.
2465 * UIProcess/API/efl/ewk_context_menu_item.h: Removed /info which is not doxygen keyword and unnecessary to the user.
2466 * UIProcess/API/efl/ewk_cookie_manager.h: Fixed parameter name.
2467 * UIProcess/API/efl/ewk_form_submission_request.h: Removed # from Eina_List because doxygen may not know the EFL structures.
2468 * UIProcess/API/efl/ewk_page_group.h: Fixed to match with parameter name.
2469 * UIProcess/API/efl/ewk_settings.h: Fixed wrong keyword and parameter name.
2470 * UIProcess/API/efl/ewk_text_checker.h: Ditto.
2471 * UIProcess/API/efl/ewk_view.h:
2472 - Used escape string for the tag.
2473 - Used @code, @endcode for media query example.
2475 2014-08-07 Benjamin Poulain <bpoulain@apple.com>
2477 Get rid of INPUT_SPEECH
2478 https://bugs.webkit.org/show_bug.cgi?id=135672
2480 Reviewed by Andreas Kling.
2482 * Configurations/FeatureDefines.xcconfig:
2483 * PlatformGTK.cmake:
2485 2014-08-07 Timothy Hatcher <timothy@apple.com>
2487 Web Inspector: Update glyphs to be more like Xcode 6
2488 https://bugs.webkit.org/show_bug.cgi?id=135705
2490 Reviewed by Joseph Pecoraro.
2492 * Resources/DockBottom.pdf: Added.
2493 * Resources/DockBottomLegacy.pdf: Copied from Source/WebKit/mac/Resources/Dock.pdf.
2494 * Resources/DockRight.pdf: Added.
2495 * Resources/DockRightLegacy.pdf: Copied from Source/WebKit2/Resources/DockRight.pdf.
2496 * UIProcess/mac/WebInspectorProxyMac.mm:
2497 (WebKit::WebInspectorProxy::createInspectorWindow): Use new images.
2498 * WebKit2.xcodeproj/project.pbxproj: Added new images.
2500 2014-08-07 Oliver Hunt <oliver@apple.com>
2502 WebContent needs access to HSTS database due to some networking still being performed in process
2503 https://bugs.webkit.org/show_bug.cgi?id=135711
2506 Reviewed by Alexey Proskuryakov.
2508 Simple patch in the same theme as the equivalent network process
2509 extension. Provide an extension that covers the WebContent specific
2510 HSTS file and consume it on launch.
2512 * Shared/WebProcessCreationParameters.cpp:
2513 (WebKit::WebProcessCreationParameters::encode):
2514 (WebKit::WebProcessCreationParameters::decode):
2515 * Shared/WebProcessCreationParameters.h:
2516 * UIProcess/WebContext.cpp:
2517 (WebKit::WebContext::createNewWebProcess):
2518 * UIProcess/WebContext.h:
2519 * UIProcess/mac/WebContextMac.mm:
2520 (WebKit::WebContext::webContentHSTSDatabasePath):
2521 * WebProcess/cocoa/WebProcessCocoa.mm:
2522 (WebKit::WebProcess::platformInitializeWebProcess):
2524 2014-08-07 Gordon Sheridan <gordon_sheridan@apple.com>
2526 Clear the m_previousItem member of HistoryControllers when it matches the HistoryItem being removed.
2527 https://bugs.webkit.org/show_bug.cgi?id=135634
2528 <rdar://problem/17388461>
2530 Reviewed by Brady Eidson.
2532 * WebProcess/WebPage/WebBackForwardListProxy.cpp:
2533 (WebKit::WebBackForwardListProxy::removeItem):
2534 Call WebCore::Page::clearPreviousItemFromAllPages() for each item removed from
2535 the back/forward list to ensure the page URL is released from IconDatabase.
2537 2014-08-07 Carlos Garcia Campos <cgarcia@igalia.com>
2539 [GTK] Use WebKitNavigationAction also for WebKitNavigationPolicyDecision
2540 https://bugs.webkit.org/show_bug.cgi?id=135695
2542 Reviewed by Gustavo Noronha Silva.
2544 WebKitNavigationAction was introduced to extend WebKitWebView::create signal
2545 and its API is mostly duplicated in WebKitNavigationPolicyDecision.
2546 Use WebKitNavigationAction insternally in WebKitNavigationPolicyDecision and
2547 deprecated all the duplicated API in favor of a single property navigation-action.
2549 * UIProcess/API/gtk/WebKitDefines.h: Remove unused macro
2550 WEBKIT_OBSOLETE and add WEBKIT_DEPRECATED and WEBKIT_DEPRECATED_FOR.
2551 * UIProcess/API/gtk/WebKitNavigationPolicyDecision.cpp:
2552 (_WebKitNavigationPolicyDecisionPrivate::~_WebKitNavigationPolicyDecisionPrivate):
2553 Free the WebKitNavigationAction.
2554 (webkitNavigationPolicyDecisionGetProperty): Add getter for
2555 navigation-action and use WebKitNavigationAction in all other getters.
2556 (webkit_navigation_policy_decision_class_init): Add navigation-action
2557 property and deprecated all others except frame-name.
2558 (webkit_navigation_policy_decision_get_navigation_action): Return the WebKitNavigationAction.
2559 (webkit_navigation_policy_decision_get_navigation_type): Use WebKitNavigationAction.
2560 (webkit_navigation_policy_decision_get_mouse_button): Ditto.
2561 (webkit_navigation_policy_decision_get_modifiers): Ditto.
2562 (webkit_navigation_policy_decision_get_request): Ditto.
2563 (webkitNavigationPolicyDecisionCreate):
2564 (webkitNewWindowPolicyDecisionCreate):
2565 * UIProcess/API/gtk/WebKitNavigationPolicyDecision.h:
2566 * UIProcess/API/gtk/WebKitNavigationPolicyDecisionPrivate.h:
2567 * UIProcess/API/gtk/WebKitPolicyClient.cpp: Use a custom
2568 PolicyClient class so that we receive a NavigationActionData in
2570 (attachPolicyClientToView):
2571 (toWebKitNavigationType): Deleted.
2572 (decidePolicyForNavigationAction): Deleted.
2573 (decidePolicyForNewWindowAction): Deleted.
2574 (decidePolicyForResponse): Deleted.
2575 * UIProcess/API/gtk/WebKitResponsePolicyDecision.cpp:
2576 (webkitResponsePolicyDecisionCreate):
2577 * UIProcess/API/gtk/WebKitResponsePolicyDecisionPrivate.h:
2578 * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add new section for
2580 * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
2582 2014-08-06 Antti Koivisto <antti@apple.com>
2584 Move Soup specific code out of WebCoreArgumentCoders.cpp
2585 https://bugs.webkit.org/show_bug.cgi?id=135665
2587 Reviewed by Anders Carlsson.
2589 * Shared/WebCoreArgumentCoders.cpp:
2590 (IPC::ArgumentCoder<ResourceRequest>::encode):
2591 (IPC::ArgumentCoder<ResourceRequest>::decode):
2592 (IPC::ArgumentCoder<ResourceError>::encode):
2593 (IPC::ArgumentCoder<ResourceError>::decode):
2594 * Shared/WebCoreArgumentCoders.h:
2596 Soup is the only client for this code. Move it to *Soup.cpp
2598 * Shared/soup/WebCoreArgumentCodersSoup.cpp:
2599 (IPC::ArgumentCoder<ResourceRequest>::encodePlatformData):
2600 (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData):
2601 (IPC::ArgumentCoder<ResourceError>::encodePlatformData):
2602 (IPC::ArgumentCoder<ResourceError>::decodePlatformData):
2604 2014-08-06 Tim Horton <timothy_horton@apple.com>
2606 Services overlay flashes a lot; should have some hysteresis before showing overlay
2607 https://bugs.webkit.org/show_bug.cgi?id=135683
2608 <rdar://problem/16878039>
2610 Reviewed by Simon Fraser.
2612 Don't show the highlight until it's been 200ms since the last change
2613 in selection or change in which highlight is hovered, whichever was more recent.
2615 * WebProcess/WebPage/ServicesOverlayController.h:
2616 * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2617 (WebKit::ServicesOverlayController::ServicesOverlayController):
2618 (WebKit::ServicesOverlayController::selectionRectsDidChange):
2619 Keep track of when the selection last changed.
2621 (WebKit::ServicesOverlayController::drawTelephoneNumberHighlightIfVisible):
2622 Make establishHoveredTelephoneHighlight take a bool instead of Boolean.
2624 (WebKit::ServicesOverlayController::mouseIsOverHighlight):
2625 Factor mouseIsOverHighlight out of establishHoveredTelephoneHighlight and drawHighlight.
2627 (WebKit::ServicesOverlayController::remainingTimeUntilHighlightShouldBeShown):
2628 Return the amount of time until the highlight should be shown; this is
2629 the maximum of (the difference between the last selection change and the timeout)
2630 and (the difference between the last change in which highlight is hovered and the timeout).
2632 Telephone number highlights are shown immediately, because they are already stable
2633 by virtue of being expanded to include the entire telephone number.
2635 (WebKit::ServicesOverlayController::repaintHighlightTimerFired):
2636 (WebKit::ServicesOverlayController::drawHighlight):
2637 If the highlight shouldn't be shown yet (because we haven't hit the two timeouts),
2638 schedule a timer to repaint us around when we will hit the timeouts.
2640 (WebKit::ServicesOverlayController::establishHoveredTelephoneHighlight):
2641 (WebKit::ServicesOverlayController::mouseEvent):
2642 Don't allow mouseUp to trigger the menu if we shouldn't be showing the overlay yet.
2644 2014-08-06 Simon Fraser <simon.fraser@apple.com>
2646 [iOS WK2] www.france24.com doesn't always load the page, sections stay white
2647 https://bugs.webkit.org/show_bug.cgi?id=135684
2648 <rdar://problem/17931712>
2650 Reviewed by Tim Horton.
2652 It's possible for a UIScrollView for overflow to move between one scrolling tree node
2653 and another. When this happens, we need to avoid unconditionally clearing the delegate
2654 on the node that's being destroyed, because the new node will already have set the
2655 UIScrollView delegate to its own delegate.
2657 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
2658 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::~ScrollingTreeOverflowScrollingNodeIOS):
2660 2014-08-06 Dean Jackson <dino@apple.com>
2662 ENABLE_CSS_TRANSFORMS_ANIMATIONS_UNPREFIXED is not used anywhere. Remove it.
2663 https://bugs.webkit.org/show_bug.cgi?id=135675
2665 Reviewed by Sam Weinig.
2667 * Configurations/FeatureDefines.xcconfig:
2669 2014-08-06 Brady Eidson and Jeffrey Pfau <beidson@apple.com>
2671 IDB transactions never reset if the Web Process ends before cleaning up
2672 https://bugs.webkit.org/show_bug.cgi?id=135218
2674 Reviewed by Darin Adler and David Kilzer.
2676 * DatabaseProcess/DatabaseToWebProcessConnection.cpp:
2677 (WebKit::DatabaseToWebProcessConnection::didReceiveMessage):
2678 (WebKit::DatabaseToWebProcessConnection::didReceiveSyncMessage): Added.
2679 (WebKit::DatabaseToWebProcessConnection::didClose):
2680 * DatabaseProcess/DatabaseToWebProcessConnection.h:
2682 * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
2683 (WebKit::DatabaseProcessIDBConnection::resetTransactionSync): Added
2684 Wait until the reset is complete before sending the sync reply.
2685 (WebKit::DatabaseProcessIDBConnection::rollbackTransactionSync): Added.
2687 * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
2688 * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
2690 Keep track of all in progress transactions and make sure they’re cleaned up
2691 whenever a connection to a WebProcess is broken:
2692 * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
2693 (WebKit::UniqueIDBDatabase::unregisterConnection):
2694 (WebKit::UniqueIDBDatabase::didCompleteTransactionOperation):
2695 (WebKit::UniqueIDBDatabase::openBackingStoreTransaction):
2696 (WebKit::UniqueIDBDatabase::resetBackingStoreTransaction):
2697 (WebKit::UniqueIDBDatabase::didEstablishTransaction):
2698 (WebKit::UniqueIDBDatabase::didResetTransaction):
2699 (WebKit::UniqueIDBDatabase::resetAllTransactions):
2700 (WebKit::UniqueIDBDatabase::finalizeRollback):
2701 * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
2703 * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
2704 (WebKit::UniqueIDBDatabaseBackingStoreSQLite::rollbackTransaction):
2706 Add sync versions of reset/rollback:
2707 * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
2708 (WebKit::WebIDBServerConnection::resetTransactionSync):
2709 (WebKit::WebIDBServerConnection::rollbackTransactionSync):
2710 * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
2712 2014-08-06 Wenson Hsieh <wenson_hsieh@apple.com>
2714 Implement parsing for CSS scroll snap points
2715 https://bugs.webkit.org/show_bug.cgi?id=134301
2717 Reviewed by Dean Jackson.
2719 * Configurations/FeatureDefines.xcconfig: Added ENABLE_CSS_SCROLL_SNAP
2721 2014-08-06 Andy Estes <aestes@apple.com>
2723 [iOS] Subresources referenced in converted QuickLook documents sometimes fail to load
2724 https://bugs.webkit.org/show_bug.cgi?id=135676
2726 Reviewed by David Kilzer.
2728 QuickLookHandle needs to stay alive in order for its NSURLProtocol to service subresource loads originating
2729 from the converted HTML document. Some of these loads happen dynamically after the main resource finishes
2730 loading, so we cannot tie the lifetime of the QuickLookHandle to that of the main resource's ResourceLoader.
2731 Instead, give ownership of the QuickLookHandle to DocumentLoader.
2733 * WebProcess/Network/WebResourceLoader.cpp:
2734 (WebKit::WebResourceLoader::didReceiveResponseWithCertificateInfo): Stored the created QuickLookHandle in DocumentLoader.
2735 (WebKit::WebResourceLoader::didReceiveData): Accessed DocumentLoader's QuickLookHandle.
2736 (WebKit::WebResourceLoader::didFinishResourceLoad): Ditto.
2737 (WebKit::WebResourceLoader::didFailResourceLoad): Ditto.
2738 (WebKit::WebResourceLoader::didReceiveResource): Ditto.
2739 * WebProcess/Network/WebResourceLoader.h: Removed m_quickLookHandle.
2741 2014-08-06 Filip Pizlo <fpizlo@apple.com>
2743 Merge r171389, r171495, r171508, r171510, r171605, r171606, r171611, r171614, r171763 from ftlopt.
2745 2014-08-06 Mark Hahnenberg <mhahnenberg@apple.com>
2747 Refactor our current implementation of for-in
2748 https://bugs.webkit.org/show_bug.cgi?id=134142
2750 Reviewed by Filip Pizlo.
2752 * WebProcess/Plugins/Netscape/JSNPObject.cpp:
2753 (WebKit::JSNPObject::invalidate): Fixed an invalid ASSERT that was crashing in debug builds.
2755 2014-08-06 Alexey Proskuryakov <ap@apple.com>
2757 REGRESSION (WebKit2): iOS Safari default encoding doesn't follow system language
2758 https://bugs.webkit.org/show_bug.cgi?id=135667
2759 <rdar://problem/17862892>
2761 Reviewed by Anders Carlsson.
2763 * Shared/WebPreferencesDefinitions.h: Compute the actual proper default, don't
2764 hardcode it to ISO-8859-1 hoping that someone else will correct it later.
2766 * Shared/WebPreferencesStore.cpp: Added an include for WebPreferencesDefinitions.h
2767 macro expansion to compile.
2769 * UIProcess/WebPreferences.cpp: (WebKit::WebPreferences::createWithLegacyDefaults):
2772 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm: (InitWebCoreSystemInterface):
2773 We now use WKGetWebDefaultCFStringEncoding in WebCore, so it needs to be initialized.
2775 2014-08-06 Adrian Perez de Castro <aperez@igalia.com>
2777 [GTK] Add support for user scripts to WebKitUserContentManager
2778 https://bugs.webkit.org/show_bug.cgi?id=134738
2780 Reviewed by Carlos Garcia Campos.
2782 Add support for user scripts, to complement the user style sheet
2783 support already present in WebKitUserContentManager. Most of the
2784 moving parts are already present, so this just adds a boxed type
2785 for user scripts (WebKitUserScript) and the corresponding methods
2786 to add and remove scripts from the WebKitUserContentManager.
2788 * UIProcess/API/gtk/WebKitUserContent.cpp: Add a WebKitUserScript
2789 boxed type and its corresponding methods and enums.
2790 (toUserScriptInjectionTime): Needed to convert
2791 WebKitUserScriptInjectionTime values into its WebCore counterparts.
2792 (_WebKitUserScript::_WebKitUserScript): Added.
2793 (_WebKitUserScript::referenceCount): Ditto.
2794 (webkit_user_script_ref):
2795 (webkit_user_script_unref):
2796 (webkit_user_script_new):
2797 (webkitUserScriptGetUserScript): Internal method to obtain the
2798 boxed WebCore::UserScript value.
2799 * UIProcess/API/gtk/WebKitUserContent.h: Add the new public API
2801 * UIProcess/API/gtk/WebKitUserContentManager.cpp: Implement the
2802 methods for adding and removing user scripts.
2803 (webkit_user_content_manager_add_script):
2804 (webkit_user_content_manager_remove_all_scripts):
2805 * UIProcess/API/gtk/WebKitUserContentManager.h: Add the new public
2807 * UIProcess/API/gtk/WebKitUserContentPrivate.h: Add the definition
2808 for the new private function.
2809 * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Include the
2810 new public methods in the API documentation.
2812 2014-08-06 Carlos Garcia Campos <cgarcia@igalia.com>
2814 [GTK] Be able to disable gtk2 dependency
2815 https://bugs.webkit.org/show_bug.cgi?id=135505
2817 Reviewed by Gustavo Noronha Silva.
2819 * PlatformGTK.cmake: Only build WebKitPluginProcess2 when
2820 ENABLE_PLUGIN_PROCESS_GTK2 is ON.
2821 * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
2822 (WebKit::ProcessLauncher::launchProcess): Do not try to launch
2823 WebKitPluginProcess2 executable when ENABLE_PLUGIN_PROCESS_GTK2 is OFF.
2825 2014-08-05 Tim Horton <timothy_horton@apple.com>
2827 REGRESSION (r164337): Pages are sometimes cut off/oriented incorrectly after using WKThumbnailView
2828 https://bugs.webkit.org/show_bug.cgi?id=135622
2829 <rdar://problem/17202556>
2831 Reviewed by Dan Bernstein.
2833 In some cases (when the page changed scroll offset while thumbnailed),
2834 when transitioning back to thumbnail scale = 1, we would get the math
2835 wrong and end up with a non-identity sublayerTransform on the DrawingArea.
2837 Luckily, none of this code is necessary anymore, as the only client
2838 of WKThumbnailView only uses its snapshotting mode.
2840 * Shared/ImageOptions.h:
2841 Remove SnapshotOptionsRespectDrawingAreaTransform; DrawingArea no longer
2842 has a rootLayerTransform().
2844 * UIProcess/WebPageProxy.cpp:
2845 (WebKit::WebPageProxy::setThumbnailScale): Deleted.
2846 * UIProcess/WebPageProxy.h:
2847 * WebProcess/WebPage/WebPage.cpp:
2848 (WebKit::WebPage::WebPage):
2849 (WebKit::WebPage::scaledSnapshotWithOptions):
2850 (WebKit::WebPage::snapshotAtSize):
2852 (WebKit::WebPage::setThumbnailScale): Deleted.
2853 * WebProcess/WebPage/WebPage.h:
2854 * WebProcess/WebPage/WebPage.messages.in:
2855 Remove setThumbnailScale and SnapshotOptionsRespectDrawingAreaTransform.
2857 * WebProcess/WebPage/WebPage.cpp:
2858 (WebKit::WebPage::didCommitLoad):
2859 Revert this to its state before r164337, as we no longer have "thumbnail scale".
2861 * UIProcess/API/Cocoa/_WKThumbnailView.h:
2862 * UIProcess/API/Cocoa/_WKThumbnailView.mm:
2863 (-[_WKThumbnailView initWithFrame:fromWKView:]):
2864 (-[_WKThumbnailView _viewWasUnparented]):
2865 (-[_WKThumbnailView _viewWasParented]):
2866 (-[_WKThumbnailView _requestSnapshotIfNeeded]):
2867 (-[_WKThumbnailView setScale:]):
2868 Clean up code assuming _shouldApplyThumbnailScale = NO, _usesSnapshot = YES.
2870 (-[_WKThumbnailView setUsesSnapshot:]):
2871 (-[_WKThumbnailView usesSnapshot]):
2872 Always return YES from usesSnapshot; we only support snapshotting WKThumbnailViews.
2873 Ignore setUsesSnapshot.
2875 * UIProcess/API/mac/WKView.mm:
2876 (-[WKView _setThumbnailView:]):
2877 (-[WKView _updateThumbnailViewLayer]):
2878 Stop checking usesSnapshot; it's always true.
2880 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2881 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2882 (WebKit::TiledCoreAnimationDrawingArea::setRootLayerTransform): Deleted.
2883 * WebProcess/WebPage/DrawingArea.cpp:
2884 (WebKit::DrawingArea::rootLayerTransform): Deleted.
2885 * WebProcess/WebPage/DrawingArea.h:
2886 (WebKit::DrawingArea::setRootLayerTransform): Deleted.
2887 Remove rootLayerTransform() and setRootLayerTransform().
2889 2014-08-05 Peyton Randolph <prandolph@apple.com>
2891 Rename MAC_LONG_PRESS feature flag to LONG_MOUSE_PRESS.
2892 https://bugs.webkit.org/show_bug.cgi?id=135276
2894 Reviewed by Beth Dakin.
2896 * Configurations/FeatureDefines.xcconfig:
2898 2014-08-04 Andy Estes <aestes@apple.com>
2900 [iOS] The raw bytes of an iWork document's PDF preview are displayed rather than the PDF itself
2901 https://bugs.webkit.org/show_bug.cgi?id=135596
2903 Reviewed by David Kilzer.
2905 * WebProcess/Network/WebResourceLoader.cpp:
2906 (WebKit::WebResourceLoader::didReceiveResponseWithCertificateInfo): If the response will be handled by
2907 QuickLook, do not call ResourceLoader::didReceiveResponse. It will be called later by
2908 WebResourceLoaderQuickLookDelegate once converted data is received.
2910 2014-08-05 Alexey Proskuryakov <ap@apple.com>
2914 * UIProcess/WebContext.h:
2916 2014-08-05 Oliver Hunt <oliver@apple.com>
2918 SSO expects to be able to walk parent application's bundle
2919 https://bugs.webkit.org/show_bug.cgi?id=135581
2920 <rdar://problem/17864079>
2922 Reviewed by Alexey Proskuryakov.
2924 SSO expects to be able to walk the parent application's
2925 bundle looking for Info plists. To allow this to actually
2926 work we provide an extension from the ui process that
2927 covers the bundle directory, and then in the profile
2928 restrict access to the ability to read directories and
2929 files named Info.plist.
2931 * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
2932 (WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
2933 * Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:
2934 * Shared/Network/NetworkProcessCreationParameters.cpp:
2935 (WebKit::NetworkProcessCreationParameters::encode):
2936 (WebKit::NetworkProcessCreationParameters::decode):
2937 * Shared/Network/NetworkProcessCreationParameters.h:
2938 * UIProcess/WebContext.cpp:
2939 (WebKit::WebContext::ensureNetworkProcess):
2940 (WebKit::WebContext::parentBundleDirectory):
2941 * UIProcess/WebContext.h:
2942 * UIProcess/mac/WebContextMac.mm:
2943 (WebKit::WebContext::parentBundleDirectory):
2945 2014-08-04 Benjamin Poulain <benjamin@webkit.org>
2947 Add a flag for the CSS Selectors level 4 implementation
2948 https://bugs.webkit.org/show_bug.cgi?id=135535
2950 Reviewed by Andreas Kling.
2952 * Configurations/FeatureDefines.xcconfig:
2954 2014-08-04 Benjamin Poulain <bpoulain@apple.com>
2956 Check for null frame when processing geolocation authorization request
2957 https://bugs.webkit.org/show_bug.cgi?id=135577
2958 <rdar://problem/17896295>
2960 Reviewed by Geoffrey Garen.
2962 I could have put the null check in GeolocationController instead of the WebKit layer,
2963 but that would be a little weird as GeolocationController knows nothing about how
2964 the WebKit layer decides what to do with requests.
2966 * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
2967 (WebKit::GeolocationPermissionRequestManager::startRequestForGeolocation):
2969 2014-08-02 Jeremy Jones <jeremyj@apple.com>
2971 Support both window and view based video fullscreen.
2972 https://bugs.webkit.org/show_bug.cgi?id=135525
2974 Reviewed by Simon Fraser.
2976 Parenting in the view instead of the window gives the fullscreen implementation more latitude
2977 in how it implements the animation.
2979 * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
2980 (WebKit::WebVideoFullscreenManagerProxy::setupFullscreenWithID): Use view instead of window.
2981 * WebProcess/ios/WebVideoFullscreenManager.mm:
2982 (WebKit::clientRectForNode): Use client rect instead of screen rect.
2983 (WebKit::WebVideoFullscreenManager::enterFullscreenForNode): ditto
2984 (WebKit::WebVideoFullscreenManager::exitFullscreenForNode): ditto
2985 (WebKit::screenRectForNode): Deleted.
2987 2014-08-01 Dan Bernstein <mitz@apple.com>
2989 <rdar://problem/17891752> [iOS] WebKit links against libraries it doesn’t use
2990 https://bugs.webkit.org/show_bug.cgi?id=135536
2992 Reviewed by Tim Horton.
2994 * Configurations/WebKit.xcconfig: Removed -lassertion_extension and -framework MobileAsset
2995 from FRAMEWORK_AND_LIBRARY_LDFLAGS_iphonesimulator.
2997 2014-08-01 Joseph Pecoraro <pecoraro@apple.com>
2999 [iOS WK2] Add extension read permission to network sandbox profile
3000 <rdar://problem/17671574>
3002 Reviewed by Alexey Proskuryakov and Oliver Hunt.
3004 * Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:
3006 2014-08-01 Oliver Hunt <oliver@apple.com>
3008 Various frameworks may want to use the container temp directory, so our current restrictions are too tight
3009 https://bugs.webkit.org/show_bug.cgi?id=135518
3012 Reviewed by Anders Carlsson.
3014 We don't (and can't) have complete knowledge of what different frameworks
3015 will want to use the container temporary directory for, and so our
3016 current attempt to heavily restrict access is simply too tight.
3018 This patch recognises this by simply giving read-write access to the
3019 entire NSTemporary() directory (e.g. $container/tmp in the general case),
3020 rather than the single sub directory we wishfully thought that we would
3021 be able to get away with.
3023 * Shared/WebProcessCreationParameters.cpp:
3024 (WebKit::WebProcessCreationParameters::encode):
3025 (WebKit::WebProcessCreationParameters::decode):
3026 * Shared/WebProcessCreationParameters.h:
3027 * UIProcess/WebContext.cpp:
3028 (WebKit::WebContext::createNewWebProcess):
3029 (WebKit::WebContext::mediaCacheDirectory): Deleted.
3030 * UIProcess/WebContext.h:
3031 * UIProcess/efl/WebContextEfl.cpp:
3032 (WebKit::WebContext::containerTemporaryDirectory):
3033 (WebKit::WebContext::platformMediaCacheDirectory): Deleted.
3034 * UIProcess/gtk/WebContextGtk.cpp:
3035 (WebKit::WebContext::containerTemporaryDirectory):
3036 (WebKit::WebContext::platformMediaCacheDirectory): Deleted.
3037 * UIProcess/mac/WebContextMac.mm:
3038 (WebKit::WebContext::containerTemporaryDirectory):
3039 (WebKit::WebContext::platformMediaCacheDirectory): Deleted.
3040 * WebProcess/cocoa/WebProcessCocoa.mm:
3041 (WebKit::WebProcess::platformInitializeWebProcess):
3043 2014-08-01 Dan Bernstein <mitz@apple.com>
3045 <rdar://problem/17862013> REGRESSION (r169357): Disabling "allow plug-ins" doesn't stick on quit/relaunch
3046 https://bugs.webkit.org/show_bug.cgi?id=135511
3048 Reviewed by Alexey Proskuryakov.
3050 Since the values map in the preferences store doesn’t include values that are equal to the
3051 defaults, we need to update it when a new default is registered.
3053 * UIProcess/WebPreferences.cpp:
3054 (WebKit::WebPreferences::createWithLegacyDefaults): Changed to use new member functions
3055 for registering defaults.
3056 (WebKit::WebPreferences::registerDefaultBoolValueForKey): Added. Sets an override default
3057 in the store, and sets the user default, if there is one, on top of it.
3058 (WebKit::WebPreferences::registerDefaultUInt32ValueForKey): Ditto.
3059 * UIProcess/WebPreferences.h: Declared new member functions for getting the user default
3062 * UIProcess/efl/WebPreferencesEfl.cpp:
3063 (WebKit::WebPreferences::platformGetStringUserValueForKey): Added an implementation that
3064 returns false, because the EFL port doesn’t support persistent user defaults.
3065 (WebKit::WebPreferences::platformGetBoolUserValueForKey): Ditto.
3066 (WebKit::WebPreferences::platformGetUInt32UserValueForKey): Ditto.
3067 (WebKit::WebPreferences::platformGetDoubleUserValueForKey): Ditto.
3069 * UIProcess/gtk/WebPreferencesGtk.cpp:
3070 (WebKit::WebPreferences::platformGetStringUserValueForKey): Ditto for the GTK port.
3071 (WebKit::WebPreferences::platformGetBoolUserValueForKey): Ditto.
3072 (WebKit::WebPreferences::platformGetUInt32UserValueForKey): Ditto.
3073 (WebKit::WebPreferences::platformGetDoubleUserValueForKey): Ditto.
3075 * UIProcess/mac/WebPreferencesMac.mm:
3076 (WebKit::WebPreferences::platformGetStringUserValueForKey): Added. Replaces
3077 setStringValueIfInUserDefaults, on which it is based.
3078 (WebKit::WebPreferences::platformGetBoolUserValueForKey): Similarly for booleans.
3079 (WebKit::WebPreferences::platformGetUInt32UserValueForKey): Similarly for integers.
3080 (WebKit::WebPreferences::platformGetDoubleUserValueForKey): Similarly for doubles.
3081 (WebKit::WebPreferences::platformInitializeStore): Changed to use the above functions.
3083 2014-08-01 Brent Fulgham <bfulgham@apple.com>
3085 [Mac] Fullscreen mode for some applications shows only a black screen.
3086 https://bugs.webkit.org/show_bug.cgi?id=135493
3087 <rdar://problem/17628212>
3089 Reviewed by Jer Noble.
3091 In some applications, the window hosting the WKView is an InProcess layer hosting mode.
3092 The fullscreen window created by the WKFullScreenWindowController defaults to an
3095 When this kind of mismatch is encountered, the WK2 layer in the UI process is supposed
3096 to send a message back to the WebProcess indicating that the layer hosting mode of the
3097 containing window is different, so that the WebProcess can adjust its logic accordingly.
3098 Unfortunately, the notification that this had happened was not getting sent to the
3099 WebProcess due to an optimization in window state change logic (see Bug 135509 for
3102 The fix is to check layer hosting mode state when a WKView is added to a window, and
3103 notify the WebProcess when it needs to change state to match.
3106 * UIProcess/API/mac/WKView.mm:
3107 (-[WKView viewDidMoveToWindow]): When moving to a new window, always call
3108 'layerHostingModeDidChange' to pick up any changes in the layer hosting mode.
3110 2014-08-01 Carlos Garcia Campos <cgarcia@igalia.com>
3112 [CMake] GTK and EFL are using PROJECT_VERSION_PATCH to define the micro version
3113 https://bugs.webkit.org/show_bug.cgi?id=135501
3115 Reviewed by Gyuyoung Kim.
3117 Use PROJECT_VERSION_MICRO instead.
3119 * UIProcess/API/efl/EWebKit2.h.in:
3120 * UIProcess/API/gtk/WebKitVersion.h.in:
3122 2014-08-01 Carlos Garcia Campos <cgarcia@igalia.com>
3124 Unreviewed. Add missing sections to documentation.
3126 * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add
3127 WebKitUserContent and WebKitUserContentManager sections to the
3130 2014-08-01 Ryuan Choi <ryuan.choi@samsung.com>
3132 [EFL] Unable to do make install since r171901
3133 https://bugs.webkit.org/show_bug.cgi?id=135497
3135 Reviewed by Gyuyoung Kim.
3137 * PlatformEfl.cmake: Removed ewk_defins.h from the installation list.
3139 2014-07-31 Ryuan Choi <ryuan.choi@samsung.com>
3141 [EFL][WK2] MiniBrower comes to crash when combo box is pressed
3142 https://bugs.webkit.org/show_bug.cgi?id=135378
3144 Reviewed by Gyuyoung Kim.
3146 Added doxygen comment of popup_menu_show/popup_menu_hide not to confuse the usage.
3148 * UIProcess/API/efl/ewk_view.h:
3150 2014-07-31 Ryuan Choi <ryuan.choi@samsung.com>
3152 [EFL] remove ewk_defines.h
3153 https://bugs.webkit.org/show_bug.cgi?id=135456
3155 Reviewed by Gyuyoung Kim.
3157 * UIProcess/API/efl/ewk_context_menu.h:
3158 * UIProcess/API/efl/ewk_context_menu_item.h: Moved the declaration from ewk_defines.h
3159 * UIProcess/API/efl/ewk_defines.h: Removed.
3161 2014-07-31 Brent Fulgham <bfulgham@apple.com>
3163 Unreviewed typo correction.
3164 https://bugs.webkit.org/show_bug.cgi?id=135482
3166 Rename '_fullScreenIsEnabled' -> '_fullScreenEnabled'
3168 * UIProcess/API/Cocoa/WKPreferences.mm:
3169 (-[WKPreferences _fullScreenEnabled]): Added
3170 (-[WKPreferences _fullScreenIsEnabled]): Deleted.
3171 * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
3173 2014-07-31 Brent Fulgham <bfulgham@apple.com>
3175 MiniBrowser Should Support Fullscreen Videos in WebKit2 Mode
3176 https://bugs.webkit.org/show_bug.cgi?id=135482
3178 Reviewed by Simon Fraser.
3180 Add accessors for the missing Fullscreen API so that MiniBrowser
3183 * UIProcess/API/Cocoa/WKPreferences.mm:
3184 (-[WKPreferences _fullScreenIsEnabled]): Added.
3185 (-[WKPreferences _setFullScreenEnabled:]): Added.
3186 * UIProcess/API/Cocoa/WKPreferencesPrivate.h: Add accessor for
3189 2014-07-31 Beth Dakin <bdakin@apple.com>
3191 Hit-testing broken in WebKit 1 views with AppKit's contentInsets
3192 https://bugs.webkit.org/show_bug.cgi?id=135434
3194 <rdar://problem/17850323>
3196 Reviewed by Benjamin Poulain.
3199 * WebProcess/Plugins/PDF/PDFPlugin.mm:
3200 (WebKit::PDFPlugin::convertFromScrollbarToContainingView):
3201 (WebKit::PDFPlugin::convertFromContainingViewToScrollbar):
3203 2014-07-31 Oliver Hunt <oliver@apple.com>
3205 Various SSO services need the networking process to be able to spoof its bundle id
3206 https://bugs.webkit.org/show_bug.cgi?id=135468
3207 <rdar://problem/17864139>
3209 Reviewed by Alexey Proskuryakov.
3211 Just add the entitlement required to allow the sandbox to let this happen.
3213 * Configurations/Network-iOS.entitlements:
3215 2014-07-31 Przemyslaw Kuczynski <p.kuczynski@samsung.com>
3217 Fix uninitialized scalar variable
3218 https://bugs.webkit.org/show_bug.cgi?id=135461
3220 Reviewed by Alexey Proskuryakov.
3222 If fopen fails, returned ApplicationMemoryStats structure will be uninitialized
3224 * Shared/linux/WebMemorySamplerLinux.cpp:
3225 (WebKit::sampleMemoryAllocatedForApplication): Initialized applicationStats.
3227 2014-07-31 Rohit Kumar <kumar.rohit@samsung.com>
3229 Clean up the WebKit build from unused parameter warning in Webkit2/WebProcess module
3230 https://bugs.webkit.org/show_bug.cgi?id=135413
3232 Reviewed by Darin Adler.
3234 * WebProcess/OriginData/WebOriginDataManager.cpp:
3235 (WebKit::WebOriginDataManager::getOrigins):
3236 (WebKit::WebOriginDataManager::deleteEntriesForOrigin):
3237 (WebKit::WebOriginDataManager::deleteEntriesModifiedBetweenDates):
3238 (WebKit::WebOriginDataManager::deleteAllEntries):
3240 2014-07-31 Chris Fleizach <cfleizach@apple.com>
3242 AX: iOS: Crash accessing m_page in WKAccessibilityPageObject
3243 https://bugs.webkit.org/show_bug.cgi?id=134617
3245 Reviewed by Darin Adler.
3247 Provide a way to detach a WK2 WebPage object so that it can uninitialize other pointers, like the accessibility object.
3249 * WebProcess/WebPage/WebPage.cpp:
3250 (WebKit::WebPage::~WebPage):
3251 * WebProcess/WebPage/WebPage.h:
3252 * WebProcess/WebPage/efl/WebPageEfl.cpp:
3253 (WebKit::WebPage::platformDetach):
3254 * WebProcess/WebPage/gtk/WebPageGtk.cpp:
3255 (WebKit::WebPage::platformDetach):
3256 * WebProcess/WebPage/ios/WebPageIOS.mm:
3257 (WebKit::WebPage::platformDetach):
3258 * WebProcess/WebPage/mac/WebPageMac.mm:
3259 (WebKit::WebPage::platformDetach):
3261 2014-07-31 Dan Bernstein <mitz@apple.com>
3263 WebKit part of: Server trust authentication challenges aren’t sent to the navigation delegate
3264 https://bugs.webkit.org/show_bug.cgi?id=135327
3266 Reviewed by Alexey Proskuryakov.
3268 * UIProcess/Cocoa/NavigationState.mm:
3269 (WebKit::NavigationState::LoaderClient::canAuthenticateAgainstProtectionSpaceInFrame):
3270 Return true for server trust protection spaces if the delegate implements
3271 -webView:didReceiveAuthenticationChallenge:completionHandler:.
3272 (WebKit::NavigationState::LoaderClient::didReceiveAuthenticationChallengeInFrame): Removed
3273 an assertion that is no longer true due to the above.
3275 2014-07-31 Carlos Garcia Campos <cgarcia@igalia.com>
3277 Unreviewed. Update OptionsGTK.cmake and NEWS for 2.5.1 release.
3279 * gtk/NEWS: Add release notes for 2.5.1.
3281 2014-07-31 Carlos Garcia Campos <cgarcia@igalia.com>
3283 Unreviewed. Fix GTK+ make distcheck.
3285 * Shared/InteractionInformationAtPosition.h: Only include
3286 WebCore/SelectionRect.h for IOS.
3288 2014-07-31 Carlos Garcia Campos <cgarcia@igalia.com>
3290 [GTK] Bump binary version for 2.6
3291 https://bugs.webkit.org/show_bug.cgi?id=133724
3293 Reviewed by Philippe Normand.
3295 * PlatformGTK.cmake: Fix JavaScriptCore dependency on
3296 instrospection commands and make them depend on GTK+-3.0.
3298 2014-07-30 Enrica Casucci <enrica@apple.com>
3300 REGRESSION (WK2 iOS): Inline editing for Chinese and Japanese keyboards does not work in Safari.
3301 https://bugs.webkit.org/show_bug.cgi?id=135449
3302 <rdar://problem/17824833>
3304 Reviewed by Benjamin Poulain.
3306 The WebProcess sends the notification that the gesture modified the phrase boundary,
3307 but the flag was not being converted properly, therefore we failed to notify
3308 the text input system that a change had occurred.
3310 * UIProcess/ios/WKContentViewInteraction.mm:
3311 (toUIWKSelectionFlags):
3313 2014-07-30 Andy Estes <aestes@apple.com>
3315 USE(CONTENT_FILTERING) should be ENABLE(CONTENT_FILTERING)
3316 https://bugs.webkit.org/show_bug.cgi?id=135439
3318 Reviewed by Tim Horton.
3320 We now support two different platform content filters, and will soon support a mock content filter (as part of
3321 webkit.org/b/128858). This makes content filtering a feature of WebKit, not just an adoption of a third-party
3322 library. ENABLE() is the correct macro to use for such a feature.
3324 * Configurations/FeatureDefines.xcconfig:
3325 * Shared/WebCoreArgumentCoders.h:
3326 * UIProcess/WebFrameProxy.cpp:
3327 (WebKit::WebFrameProxy::didStartProvisionalLoad):
3328 * UIProcess/WebFrameProxy.h:
3329 * UIProcess/WebPageProxy.cpp:
3330 (WebKit::WebPageProxy::decidePolicyForNavigationAction):
3331 * UIProcess/WebPageProxy.h:
3332 * UIProcess/WebPageProxy.messages.in:
3333 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3334 * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3336 2014-07-30 Andreas Kling <akling@apple.com>
3338 Static hash tables no longer need to be coupled with a VM.
3339 <https://webkit.org/b/135421>
3341 Reviewed by Geoffrey Garen.
3343 * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
3344 * WebProcess/Plugins/Netscape/JSNPObject.cpp:
3346 2014-07-30 Dan Bernstein <mitz@apple.com>
3348 Get rid of the WKNSURLProtectionSpace wrapper
3349 https://bugs.webkit.org/show_bug.cgi?id=135425
3351 Reviewed by Sam Weinig.
3353 * Shared/Cocoa/APIObject.mm:
3354 (API::Object::newObject): Don’t allocate WKNSURLProtectionSpace wrappers.
3356 * Shared/Cocoa/WKNSURLProtectionSpace.h: Removed.
3357 * Shared/Cocoa/WKNSURLProtectionSpace.mm: Removed.
3359 * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
3360 (canAuthenticateAgainstProtectionSpaceInFrame): Get the NSURLProtectionSpace from the
3361 WebCore::ProtectionSpace in the WebProtectionSpace.
3363 * UIProcess/Cocoa/NavigationState.mm:
3364 (WebKit::NavigationState::LoaderClient::canAuthenticateAgainstProtectionSpaceInFrame): Ditto.
3366 * WebKit2.xcodeproj/project.pbxproj: Removed references to removed files.
3368 2014-07-30 Dan Bernstein <mitz@apple.com>
3370 Updated for changes to the WebCore::Credential API.
3371 Work towards fixing https://bugs.webkit.org/show_bug.cgi?id=135327
3373 Reviewed by Alexey Proskuryakov.
3375 * Shared/Downloads/mac/DownloadMac.mm:
3376 (WebKit::Download::receivedCredential):Use new Credential::nsCredential getter.
3378 * Shared/WebCoreArgumentCoders.cpp:
3379 (IPC::ArgumentCoder<Credential>::encode): If encoding the credential requires encoding the
3380 platform data, do that.
3381 (IPC::ArgumentCoder<Credential>::decode): If platform data was encoded, decode it.
3382 * Shared/WebCoreArgumentCoders.h:
3384 * Shared/mac/WebCoreArgumentCodersMac.mm:
3385 (IPC::ArgumentCoder<Credential>::encodePlatformData): Archive the NSURLCredential.
3386 (IPC::ArgumentCoder<Credential>::decodePlatformData): Unarchive it.
3388 * UIProcess/API/Cocoa/WKNSURLAuthenticationChallenge.mm:
3389 (-[WKNSURLAuthenticationChallengeSender useCredential:forAuthenticationChallenge:]): Use
3390 Credential constructor that takes an NSURLCredential.
3392 * UIProcess/Cocoa/NavigationState.mm:
3393 (WebKit::NavigationState::LoaderClient::didReceiveAuthenticationChallengeInFrame): Ditto.
3396 2014-07-30 Carlos Garcia Campos <cgarcia@igalia.com>
3398 [GTK] REGRESSION(r171742): Test /webkit2/WebKitWebView/disallow-modal-dialogs fails
3399 https://bugs.webkit.org/show_bug.cgi?id=135412
3401 Reviewed by Philippe Normand.
3403 The problem is that WebPageProxy::setUIClient() calls
3404 setCanRunModal() with the value of m_uiClient->canRunModal() which
3405 is always true for us. We override that manually by calling
3406 setCanRunModal() depending on the WebKitSettings. In r171742,
3407 webkitWebViewUpdateSettings(), the method that overrides
3408 setCanRunModal(), was moved before attachUIClientToView(), so the
3409 value set by WebPageProxy::setUIClient() is the last one and takes
3410 precedence. We need to make sure webkitWebViewUpdateSettings() is
3411 always called after attachUIClientToView().
3413 * UIProcess/API/gtk/WebKitWebView.cpp:
3414 (webkitWebViewConstructed): Move webkitWebViewUpdateSettings()
3415 call after attachUIClientToView() and add a comment to not forget
3418 2014-07-29 Carlos Garcia Campos <cgarcia@igalia.com>
3420 [GTK] Remove WebKitCertificateInfo from WebKit2GTK+ API
3421 https://bugs.webkit.org/show_bug.cgi?id=134830
3423 Reviewed by Gustavo Noronha Silva.
3425 It was added to make the API more convenient but it has ended up
3426 making it more complicated. WebKitWebView::load-failed-with-tls-errors
3427 now receives a GTlsCertificate + GTlsCertificateFlags and
3428 webkit_web_context_allow_tls_certificate_for_host() receives a GTlsCertificate
3429 since the errors are not actually needed. This makes the API more
3430 consistent with the existing method webkit_web_view_get_tls_info().
3432 * PlatformGTK.cmake: Remove files from compilation.
3433 * UIProcess/API/gtk/WebKitCertificateInfo.cpp: Removed.
3434 * UIProcess/API/gtk/WebKitCertificateInfo.h: Removed.
3435 * UIProcess/API/gtk/WebKitCertificateInfoPrivate.h: Removed.
3436 * UIProcess/API/gtk/WebKitWebContext.cpp:
3437 (webkit_web_context_allow_tls_certificate_for_host):
3438 * UIProcess/API/gtk/WebKitWebContext.h:
3439 * UIProcess/API/gtk/WebKitWebView.cpp:
3440 (webkit_web_view_class_init):
3441 (webkitWebViewLoadFailedWithTLSErrors):
3442 * UIProcess/API/gtk/WebKitWebView.h:
3443 * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml:
3444 * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
3445 * UIProcess/API/gtk/webkit2.h:
3447 2014-07-29 Jinwoo Song <jinwoo7.song@samsung.com>