1 2014-05-02 Dan Bernstein <mitz@apple.com>
3 [Cocoa] Remove unused WKErrorRecoveryAttempting
4 https://bugs.webkit.org/show_bug.cgi?id=132503
6 Reviewed by Anders Carlsson.
8 * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
9 (didFailProvisionalLoadWithErrorForFrame):
10 (didFailLoadWithErrorForFrame):
11 (createErrorWithRecoveryAttempter): Deleted.
12 (-[WKBrowsingContextController attemptRecoveryFromError:]): Deleted.
13 * UIProcess/API/Cocoa/WKErrorRecoveryAttempting.m: Removed.
14 * UIProcess/API/Cocoa/_WKFormDelegate.h:
15 * WebKit2.xcodeproj/project.pbxproj:
17 2014-05-02 Enrica Casucci <enrica@apple.com>
19 REGRESSION (WebKit2) Need to support reanalyze button for Chinese Traditional.
20 https://bugs.webkit.org/show_bug.cgi?id=132504
21 <rdar://problem/16778862>
23 Reviewed by Benjamin Poulain.
25 For traditional Chinese we support reanalyzing of the text to perform
26 transformations on the text based on the selected language and keyboard.
27 This is done by pressing the Reanalyze button on the system
28 menu. This patch adds the necessary code to canPerformAction to enable
29 the button when appropriate as well as the implementation of the action
32 * UIProcess/ios/WKContentViewInteraction.mm:
33 (-[WKContentView _reanalyze:]):
34 (-[WKContentView canPerformAction:withSender:]):
36 2014-05-02 Enrica Casucci <enrica@apple.com>
38 REGRESSION (WebKit2) Need to support transliterate chinese button (简⇄繁) for Traditional Chinese.
39 https://bugs.webkit.org/show_bug.cgi?id=132500
40 <rdar://problem/16778870>
42 Reviewed by Benjamin Poulain.
44 For traditional Chinese we support the transliterate to simplified Chinese.
45 This is done by pressing the 简⇄繁 button on the system
46 menu. This patch adds the necessary code to canPerformAction to enable
47 the button when appropriate as well as the implementation of the action
50 * UIProcess/ios/WKContentViewInteraction.mm:
51 (-[WKContentView _transliterateChinese:]):
52 (-[WKContentView canPerformAction:withSender:]):
54 2014-05-02 Jeremy Jones <jeremyj@apple.com>
56 Fullscreen UI does not appear after WebProcess has crashed
57 https://bugs.webkit.org/show_bug.cgi?id=132442
59 Reviewed by Darin Adler.
61 Cleanup WebVideoFullscreenManagerProxy after a WebProcess crash.
63 * UIProcess/WebPageProxy.cpp:
64 (WebKit::WebPageProxy::reattachToWebProcess):
65 recreate WebVideoFullscreenManagerProxy after a WebProcess crash.
67 (WebKit::WebPageProxy::resetState):
68 invalidate and release WebVideoFullscreenManagerProxy on crash.
70 * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
71 * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
72 (WebKit::WebVideoFullscreenManagerProxy::~WebVideoFullscreenManagerProxy):
73 don't assume m_page is valid.
75 (WebKit::WebVideoFullscreenManagerProxy::invalidate):
76 do cleanup invalidation in reponse to a WebProcess crash.
78 2014-05-02 Benjamin Poulain <bpoulain@apple.com>
80 [iOS][WK2] More animation madness for when the extendedBackground is modified in an animation block
81 https://bugs.webkit.org/show_bug.cgi?id=132497
83 Reviewed by Beth Dakin.
85 * UIProcess/API/Cocoa/WKWebView.mm:
86 (updateTopAndBottomExtendedBackgroundExclusionIfNecessary):
87 Do not early return when _extendedBackgroundExclusionInsets.left is empty. That way, if executed in an animation block,
88 the top of bottom view will animate from their current size to an empty width.
90 When creating the layer, set up their height without animation. Otherwise it is possible to see the height animating
91 while the left inset is animating.
93 (-[WKWebView _setExtendedBackgroundExclusionInsets:]):
94 When replacing the scrollview, make sure the frame and color are not animated. Otherwise the transition between
95 scrollView and _mainExtendedBackgroundView can be visible if _setExtendedBackgroundExclusionInsets: is invoked
96 in an animation block.
98 (-[WKWebView _endAnimatedResize]):
99 Nuke the top and bottom insets when possible. [WKWebView _endAnimatedResize] is unfrequent, so it is a good opportunity
102 2014-05-02 Alexey Proskuryakov <ap@apple.com>
104 Remove Blob contentDisposition handling
105 https://bugs.webkit.org/show_bug.cgi?id=132490
107 Reviewed by Sam Weinig.
109 * Shared/FileAPI/BlobRegistrationData.cpp:
110 (WebKit::BlobRegistrationData::encode):
111 (WebKit::BlobRegistrationData::decode):
113 2014-05-02 Benjamin Poulain <benjamin@webkit.org>
115 [iOS][WK2] Adapt the rubberband constraints when the page get smaller than the scrollview - insets
116 https://bugs.webkit.org/show_bug.cgi?id=132457
118 Reviewed by Enrica Casucci.
120 It is quite common for us to have a WKContentView that is scalled smaller than the WKWebView, content
123 In those cases, update the constraints to fit the content properly in the view.
125 * UIProcess/ios/WKScrollView.mm:
126 (valuesAreWithinOnePixel):
127 (-[WKScrollView _rubberBandOffsetForOffset:maxOffset:minOffset:range:outside:]):
129 2014-05-02 Mark Rowe <mrowe@apple.com>
131 -[_WKThumbnailView _requestSnapshotIfNeeded] assumes that taking a snapshot will always succeed
132 <https://webkit.org/b/132489> / <rdar://problem/16704660>
134 Reviewed by Tim Horton.
136 * UIProcess/API/Cocoa/_WKThumbnailView.mm:
137 (-[_WKThumbnailView _requestSnapshotIfNeeded]): Don't attempt to create a CGImageRef if we failed
138 to create a ShareableBitmap. This handles both the callback receiving a null Handle and a failure
139 within ShareableBitmap::create.
141 2014-05-02 Anders Carlsson <andersca@apple.com>
143 Clean up FormDataElement
144 https://bugs.webkit.org/show_bug.cgi?id=132483
146 Reviewed by Sam Weinig.
148 * NetworkProcess/NetworkResourceLoader.cpp:
149 (WebKit::NetworkResourceLoader::NetworkResourceLoader):
150 * Shared/Network/NetworkResourceLoadParameters.cpp:
151 (WebKit::NetworkResourceLoadParameters::encode):
153 2014-05-02 Anders Carlsson <andersca@apple.com>
155 Add and implement KeyedDecoder::decodeBytes
156 https://bugs.webkit.org/show_bug.cgi?id=132479
158 Reviewed by Tim Horton.
160 * Shared/cf/KeyedDecoder.cpp:
161 (WebKit::KeyedDecoder::decodeBytes):
162 * Shared/cf/KeyedDecoder.h:
164 2014-05-02 Joseph Pecoraro <pecoraro@apple.com>
166 [iOS] WebKit2 File Upload Support
167 https://bugs.webkit.org/show_bug.cgi?id=132024
169 Reviewed by Enrica Casucci.
171 * Configurations/WebKit2.xcconfig:
172 Include MobileCoreServices on iOS for kUTTypeImage/kUTTypeMovie.
174 * WebKit2.xcodeproj/project.pbxproj:
177 * UIProcess/WebOpenPanelResultListenerProxy.h:
178 * UIProcess/WebOpenPanelResultListenerProxy.cpp:
179 (WebKit::filePathsFromFileURLs):
180 (WebKit::WebOpenPanelResultListenerProxy::chooseFiles):
181 * UIProcess/WebPageProxy.h:
182 * UIProcess/WebPageProxy.cpp:
183 (WebKit::WebPageProxy::runOpenPanel):
184 (WebKit::WebPageProxy::didChooseFilesForOpenPanelWithDisplayStringAndIcon):
185 * WebProcess/WebPage/WebOpenPanelResultListener.h:
186 * WebProcess/WebPage/WebOpenPanelResultListener.cpp:
187 (WebKit::WebOpenPanelResultListener::didChooseFilesWithDisplayStringAndIcon):
188 * WebProcess/WebPage/WebPage.h:
189 * WebProcess/WebPage/WebPage.messages.in:
190 * WebProcess/WebPage/WebPage.cpp:
191 (WebKit::WebPage::didChooseFilesForOpenPanelWithDisplayStringAndIcon):
192 Message forwarding for choosing files and providing a display string and icon,
193 leading down to the existing WebCore FileChooser method.
195 * UIProcess/PageClient.h:
196 * UIProcess/ios/PageClientImplIOS.h:
197 * UIProcess/ios/PageClientImplIOS.mm:
198 (WebKit::PageClientImpl::handleRunOpenPanel):
199 Add a default handler for file open panel on iOS.
200 Forwards to the content view.
202 * UIProcess/ios/WKContentViewInteraction.h:
203 * UIProcess/ios/WKContentViewInteraction.mm:
204 (-[WKContentView lastInteractionLocation]):
205 (-[WKContentView _webTouchEventsRecognized:]):
206 (-[WKContentView _highlightLongPressRecognized:]):
207 (-[WKContentView _longPressRecognized:]):
208 (-[WKContentView _singleTapRecognized:]):
209 (-[WKContentView _doubleTapRecognized:]):
210 (-[WKContentView _twoFingerDoubleTapRecognized:]):
211 Keep track of the last interaction location. This matches previous behavior
212 of showing the file upload popover where the user tapped, to handle
213 cases where the <input> is hidden.
215 (-[WKContentView _showRunOpenPanel:resultListener:]):
216 (-[WKContentView fileUploadPanelDidDismiss:]):
217 Handle showing the cleaning up after the file upload panel.
219 * UIProcess/ios/forms/WKFileUploadPanel.h:
220 * UIProcess/ios/forms/WKFileUploadPanel.mm: Added.
221 (squareCropRectForSize):
223 (thumbnailSizedImageForImage):
224 (-[_WKFileUploadItem isVideo]):
225 (-[_WKFileUploadItem fileURL]):
226 (-[_WKFileUploadItem displayImage]):
227 (-[_WKImageFileUploadItem initWithFilePath:originalImage:]):
228 (-[_WKImageFileUploadItem isVideo]):
229 (-[_WKImageFileUploadItem fileURL]):
230 (-[_WKImageFileUploadItem displayImage]):
231 (-[_WKVideoFileUploadItem initWithFilePath:mediaURL:]):
232 (-[_WKVideoFileUploadItem isVideo]):
233 (-[_WKVideoFileUploadItem fileURL]):
234 (-[_WKVideoFileUploadItem displayImage]):
235 Helper class for each image picker selection. Knows how to get
236 a file URL and thumbnail display image for the item.
238 (-[WKFileUploadPanel initWithView:]):
239 (-[WKFileUploadPanel dealloc]):
240 (-[WKFileUploadPanel _dispatchDidDismiss]):
241 (-[WKFileUploadPanel _cancel]):
242 (-[WKFileUploadPanel _chooseFiles:displayString:iconImage:]):
243 Lifetime of the upload panel requires that either cancel or choose
244 must happen as we go through the file picking process.
246 (-[WKFileUploadPanel presentWithParameters:WebKit::resultListener:WebKit::]):
247 (-[WKFileUploadPanel dismiss]):
248 API to show or dismiss the panel.
250 (-[WKFileUploadPanel _dismissDisplayAnimated:]):
251 Helper to clean up the UI as it progresses or completes no matter the device idiom.
253 (-[WKFileUploadPanel _presentPopoverWithContentViewController:animated:]):
254 (-[WKFileUploadPanel _presentFullscreenViewController:animated:]):
255 UI presentation for the appropriate idiom.
257 (-[WKFileUploadPanel _mediaTypesForPickerSourceType:]):
258 (-[WKFileUploadPanel _showMediaSourceSelectionSheet]):
259 (-[WKFileUploadPanel _showPhotoPickerWithSourceType:]):
260 Showing the action sheet or image picker.
262 (-[WKFileUploadPanel popoverControllerDidDismissPopover:]):
263 (-[WKFileUploadPanel _willMultipleSelectionDelegateBeCalled]):
264 (-[WKFileUploadPanel imagePickerController:didFinishPickingMediaWithInfo:]):
265 (-[WKFileUploadPanel imagePickerController:didFinishPickingMultipleMediaWithInfo:]):
266 (-[WKFileUploadPanel imagePickerControllerDidCancel:]):
267 Action sheet or image picker handlers.
269 (-[WKFileUploadPanel _processMediaInfoDictionaries:successBlock:failureBlock:]):
270 (-[WKFileUploadPanel _processMediaInfoDictionaries:atIndex:processedResults:processedImageCount:processedVideoCount:successBlock:failureBlock:]):
271 (-[WKFileUploadPanel _uploadItemFromMediaInfo:successBlock:failureBlock:]):
272 (-[WKFileUploadPanel _displayStringForPhotos:videos:]):
273 Processing selections from the image picker to FileUploadItems.
275 2014-05-01 Simon Fraser <simon.fraser@apple.com>
277 [iOS WK2] Animations on vox.com look wrong
278 https://bugs.webkit.org/show_bug.cgi?id=132462
279 <rdar://problem/16731884>
281 Reviewed by Sam Weinig.
283 PlatformCALayerRemote was managing animations incorrectly; aninations
284 would stick around in m_properties.addedAnimations and get added a second
287 Animations have to be managed a little differently to other properties,
288 since they are not steady-state things. A given commit has to send over
289 the added and removed animations, and then clear the layer properties.
291 Do this by adding PlatformCALayerRemote::didCommit(), which is called
292 after the layer properties have been encoded, and have it clear the lists
293 of added and removed animations.
295 removeAnimationForKey() also has to remove the animation from addedAnimations
296 so that an add/remove in the same commit doesn't send the animation to the
299 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
300 (WebKit::PlatformCALayerRemote::recursiveBuildTransaction):
301 (WebKit::PlatformCALayerRemote::didCommit):
302 (WebKit::PlatformCALayerRemote::removeAnimationForKey):
303 * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
304 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
305 (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
307 2014-05-01 Simon Fraser <simon.fraser@apple.com>
309 [iOS WK2] Can't scroll on gatesnotes.com
310 https://bugs.webkit.org/show_bug.cgi?id=132459
311 <rdar://problem/16770909>
313 Reviewed by Benjamin Poulain.
315 The custom UIView hit-testing code was finding views that were created by
316 the compositing code for clipping, above the UIScrollViews. We only ever
317 need to find UIScrollViews here for touch overflow-scrolling, so constrain
318 the hit-testing code to only return UIScrollViews.
320 * UIProcess/ios/RemoteLayerTreeHostIOS.mm:
321 (-[UIView _recursiveFindDescendantScrollViewAtPoint:withEvent:]):
322 (-[UIView _findDescendantViewAtPoint:withEvent:]):
323 (-[UIView _recursiveFindDescendantViewAtPoint:withEvent:]): Deleted.
325 2014-05-02 Carlos Alberto Lopez Perez <clopez@igalia.com>
327 REGRESSION(r168118): [GTK] build broken due to shouldTrackVisitedLinks
328 https://bugs.webkit.org/show_bug.cgi?id=132447
330 Unreviewed GTK build fix.
332 shouldTrackVisitedLinks was removed on r168118.
333 Visited link coloring works as expected after this change.
335 * UIProcess/gtk/WebContextGtk.cpp:
336 (WebKit::WebContext::platformInitializeWebProcess): Remove
337 shouldTrackVisitedLinks parameter.
339 2014-05-01 Enrica Casucci <enrica@apple.com>
341 REGRESSION (WebKit2) Need to support Learn button.
342 https://bugs.webkit.org/show_bug.cgi?id=132454
343 <rdar://problem/16778889>
345 Reviewed by Benjamin Poulain.
347 For traditional Chinese we support the ability to add shortcuts
348 for typing. This is done by pressing the Learn button on the system
349 menu. This patch adds the necessary code to canPerformAction to enable
350 the button when appropriate as well as the implementation of the action
352 It also adds a check for the Replace button not to be shown when the
353 selection only contains CJ characters.
355 * UIProcess/ios/WKContentViewInteraction.mm:
356 (-[WKContentView _addShortcut:]):
357 (-[WKContentView canPerformAction:withSender:]):
359 2014-05-01 Benjamin Poulain <bpoulain@apple.com>
361 [iOS][WK2] Tweak the extended background exclusion for MobileSafari
362 https://bugs.webkit.org/show_bug.cgi?id=132449
364 Reviewed by Beth Dakin.
366 Some tweaks for Mobile:
367 -Use UIViews instead of CALayers to have the same animation timing as the top views.
368 -The left extended background insets should not exclude the top and bottom insets.
370 Since this code is in the middle of 2 hot paths, also added some performance tweaks.
372 * UIProcess/API/Cocoa/WKWebView.mm:
373 (-[WKWebView initWithFrame:configuration:]):
374 In the normal case, we do not have extended background exclusion. To avoid creating a background view, we use
375 the scrollview to render the background.
376 The separate background view is created lazily if needed.
378 (-[WKWebView _updateScrollViewBackground]):
379 (-[WKWebView _frameOrBoundsChanged]):
380 (updateTopAndBottomExtendedBackgroundExclusionIfNecessary):
381 This create the top and bottom extended background view as needed and update their frames for the current insets.
383 (-[WKWebView _setObscuredInsets:]):
384 (-[WKWebView _setExtendedBackgroundExclusionInsets:]):
385 When an exclusion inset is needed, create a view for it, transfer the color from the ScrollView, and reset the color
388 2014-05-01 Alexey Proskuryakov <ap@apple.com>
390 Move size computation for Blob constructor into BlobRegistryImpl
391 https://bugs.webkit.org/show_bug.cgi?id=132439
393 Reviewed by Sam Weinig.
395 Plumbing to make this version of registerBlobURL synchronous for now.
396 I expect to make it async again when data structures on client side are simplified.
398 * NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
399 (WebKit::NetworkBlobRegistry::registerBlobURL):
400 * NetworkProcess/FileAPI/NetworkBlobRegistry.h:
401 * NetworkProcess/NetworkConnectionToWebProcess.cpp:
402 (WebKit::NetworkConnectionToWebProcess::registerBlobURL):
403 * NetworkProcess/NetworkConnectionToWebProcess.h:
404 * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
405 * WebProcess/FileAPI/BlobRegistryProxy.cpp:
406 (WebKit::BlobRegistryProxy::registerBlobURL):
407 * WebProcess/FileAPI/BlobRegistryProxy.h:
409 2014-05-01 Beth Dakin <bdakin@apple.com>
411 REGRESSION(168053): Repro crash navigating to another page after selecting phone
413 https://bugs.webkit.org/show_bug.cgi?id=132444
415 <rdar://problem/16787285>
417 Reviewed by Darin Adler.
420 * WebProcess/WebPage/mac/TelephoneNumberOverlayControllerMac.mm:
421 (WebKit::TelephoneNumberOverlayController::drawRect):
423 2014-05-01 Anders Carlsson <andersca@apple.com>
425 Remove WKBundleSetShouldTrackVisitedLinks and associate code
426 https://bugs.webkit.org/show_bug.cgi?id=132441
428 Reviewed by Sam Weinig.
430 * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
431 (WKBundleSetShouldTrackVisitedLinks): Deleted.
432 * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
433 * WebProcess/InjectedBundle/InjectedBundle.cpp:
434 (WebKit::InjectedBundle::setShouldTrackVisitedLinks): Deleted.
435 * WebProcess/InjectedBundle/InjectedBundle.h:
436 * WebProcess/WebPage/VisitedLinkTableController.cpp:
437 (WebKit::VisitedLinkTableController::addVisitedLink):
438 * WebProcess/WebProcess.cpp:
439 (WebKit::WebProcess::WebProcess):
440 (WebKit::WebProcess::setShouldTrackVisitedLinks): Deleted.
441 * WebProcess/WebProcess.h:
442 (WebKit::WebProcess::shouldTrackVisitedLinks): Deleted.
444 2014-05-01 Anders Carlsson <andersca@apple.com>
446 window.testRunner.keepWebHistory() should update the UI process state
447 https://bugs.webkit.org/show_bug.cgi?id=132440
449 Reviewed by Dan Bernstein.
451 * UIProcess/API/C/WKPage.cpp:
452 (WKPageGetAddsVisitedLinks):
453 (WKPageSetAddsVisitedLinks):
454 * UIProcess/API/C/WKPagePrivate.h:
456 2014-05-01 Filip Pizlo <fpizlo@apple.com>
460 Rubber stamped by Mark Hahnenberg.
462 This breaks our debugging workflow.
464 * Shared/WebProcessCreationParameters.cpp:
465 (WebKit::WebProcessCreationParameters::decode):
466 * UIProcess/mac/WebContextMac.mm:
467 (WebKit::registerUserDefaultsIfNeeded):
468 (WebKit::WebContext::platformInitializeWebProcess):
470 2014-05-01 Anders Carlsson <andersca@apple.com>
472 WKWebView doesn't track visited links (for visited link coloring)
473 https://bugs.webkit.org/show_bug.cgi?id=132438
474 <rdar://problem/16704519>
476 Reviewed by Dan Bernstein.
478 * Shared/WebProcessCreationParameters.cpp:
479 (WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
480 (WebKit::WebProcessCreationParameters::encode):
481 (WebKit::WebProcessCreationParameters::decode):
482 * Shared/WebProcessCreationParameters.h:
483 * UIProcess/API/APIHistoryClient.h:
484 (API::HistoryClient::addsVisitedLinks):
485 (API::HistoryClient::shouldTrackVisitedLinks): Deleted.
486 * UIProcess/API/C/WKContext.cpp:
487 (WKContextSetHistoryClient):
488 * UIProcess/API/Cocoa/WKWebView.mm:
489 (-[WKWebView _addsVisitedLinks]):
490 (-[WKWebView _setAddsVisitedLinks:]):
491 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
492 * UIProcess/API/mac/WKView.mm:
493 (-[WKView initWithFrame:context:configuration:webView:]):
494 * UIProcess/Cocoa/HistoryClient.h:
495 * UIProcess/Cocoa/HistoryClient.mm:
496 (WebKit::HistoryClient::shouldTrackVisitedLinks): Deleted.
497 * UIProcess/VisitedLinkProvider.cpp:
498 (WebKit::VisitedLinkProvider::addVisitedLinkHashFromPage):
499 * UIProcess/VisitedLinkProvider.h:
500 * UIProcess/VisitedLinkProvider.messages.in:
501 * UIProcess/WebContext.cpp:
502 (WebKit::WebContext::setHistoryClient):
503 (WebKit::WebContext::createNewWebProcess):
504 * UIProcess/WebContext.h:
505 (WebKit::WebContext::processes):
506 * UIProcess/WebPageProxy.cpp:
507 (WebKit::WebPageProxy::WebPageProxy):
508 * UIProcess/WebPageProxy.h:
509 (WebKit::WebPageProxy::addsVisitedLinks):
510 (WebKit::WebPageProxy::setAddsVisitedLinks):
511 * WebProcess/WebPage/VisitedLinkTableController.cpp:
512 (WebKit::VisitedLinkTableController::addVisitedLink):
513 * WebProcess/WebProcess.cpp:
514 (WebKit::WebProcess::initializeWebProcess):
515 * WebProcess/WebProcess.h:
516 * WebProcess/WebProcess.messages.in:
518 2014-05-01 Benjamin Poulain <bpoulain@apple.com>
520 [iOS][WK2] The highlight view needs to be in WKWebView coordinates
521 https://bugs.webkit.org/show_bug.cgi?id=132435
522 <rdar://problem/16708861>
524 Reviewed by Tim Horton.
526 _UIHighlightView needs to be in WKWebView coordinates so that it render unscaled for any page scale factor.
527 The view needs to be a child of WKContentView so that it moves/scales with the page.
529 To fix the issue, add an inverse transform root layer for the hightlight, and scale the coordinates to their
530 inverse scaled counterpart.
532 The scale is not updated live with the scaling of WKContentView but that should be fine since the view disappear
533 on any scaling operation (and I would prefer not add live painting during scaling animation).
535 * UIProcess/ios/WKContentViewInteraction.h:
536 * UIProcess/ios/WKContentViewInteraction.mm:
537 (-[WKContentView cleanupInteraction]):
538 (-[WKContentView _didGetTapHighlightForRequest:color:WebCore::quads:WebCore::topLeftRadius:WebCore::topRightRadius:WebCore::bottomLeftRadius:WebCore::bottomRightRadius:WebCore::]):
539 (-[WKContentView _cancelInteraction]):
541 2014-05-01 Ryuan Choi <ryuan.choi@samsung.com>
543 [EFL] There are many warnings with software backend
544 https://bugs.webkit.org/show_bug.cgi?id=132422
546 Reviewed by Gyuyoung Kim.
548 * UIProcess/API/efl/EwkView.cpp:
549 (EwkView::updateCursor):
550 (EwkView::transformToScreen):
552 2014-04-30 Alexey Proskuryakov <ap@apple.com>
554 Roll out fix for https://bugs.webkit.org/show_bug.cgi?id=131637:
555 Clean up unnecessary methods in the BackForwardClient interface
557 It broke a regression test and an API test.
559 * WebKit2.xcodeproj/project.pbxproj:
560 * WebProcess/InjectedBundle/InjectedBundleBackForwardList.cpp:
561 (WebKit::InjectedBundleBackForwardList::clear):
562 * WebProcess/WebPage/WebBackForwardListProxy.cpp:
563 (WebKit::WebBackForwardListProxy::WebBackForwardListProxy):
564 (WebKit::WebBackForwardListProxy::addItem):
565 (WebKit::WebBackForwardListProxy::goToItem):
566 (WebKit::WebBackForwardListProxy::itemAtIndex):
567 (WebKit::WebBackForwardListProxy::backListCount):
568 (WebKit::WebBackForwardListProxy::forwardListCount):
569 (WebKit::WebBackForwardListProxy::close):
570 (WebKit::WebBackForwardListProxy::clear):
571 * WebProcess/WebPage/WebBackForwardListProxy.h:
572 (WebKit::WebBackForwardListProxy::create):
573 * WebProcess/WebPage/WebPage.cpp:
574 (WebKit::WebPage::WebPage):
575 * WebProcess/WebPage/ios/WebBackForwardListProxyIOS.mm: Copied from Source/WebKit2/WebProcess/WebPage/ios/WebBackForwardListProxyIOS.mm.
577 2014-04-30 Brady Eidson <beidson@apple.com>
579 Only reveal selection service UI after a short delay.
580 <rdar://problem/16777346> and https://bugs.webkit.org/show_bug.cgi?id=132418
582 Reviewed by Sam Weinig.
584 * WebProcess/WebPage/SelectionOverlayController.cpp:
585 (WebKit::SelectionOverlayController::SelectionOverlayController):
586 (WebKit::SelectionOverlayController::destroyOverlay): Also stop the hover timer.
587 (WebKit::SelectionOverlayController::selectionRectsDidChange): Mark the highlight as dirty.
588 (WebKit::SelectionOverlayController::hoverTimerFired): If the mouse is still over the highlight,
589 set the visible flag and setNeedsDisplay().
590 * WebProcess/WebPage/SelectionOverlayController.h:
592 * WebProcess/WebPage/mac/SelectionOverlayControllerMac.mm:
593 (WebKit::SelectionOverlayController::drawRect): Recreate the highlight if it exists but
594 is marked as dirty. After doing that, possibly reset the hover timer.
595 Also, only performing the actual drawing if the visible flag is set.
596 (WebKit::SelectionOverlayController::mouseEvent): If the mouse moves on or off the highlight,
597 start or stop the hover timer accordingly.
598 (WebKit::SelectionOverlayController::mouseHoverStateChanged): Handle starting/stopping the
600 (WebKit::SelectionOverlayController::clearHighlight): Deleted.
602 2014-04-30 Benjamin Poulain <benjamin@webkit.org>
604 [iOS][WK2] Animated resize incorrectly assumes the layout width is the same as the view width
605 https://bugs.webkit.org/show_bug.cgi?id=132373
606 <rdar://problem/16762178>
608 Reviewed by Tim Horton.
610 * UIProcess/API/Cocoa/WKWebView.mm:
611 (-[WKWebView _beginAnimatedResizeWithUpdates:]):
612 Fix a couple of bugs when the left/right obscured insets change, and/or when the minimum layout size
613 is narrower than the view itself.
616 -We need to perfom and update if the insets change since the unobscuredRect will also change.
617 -The min/max zoom scale should be based on the minimum layout size, that's the definition of minimum layout size
618 in scrollview coordinate :)
619 -The old web view width in content coordinate could be narrower than the old view bounds if there are left or right
622 2014-04-30 Simon Fraser <simon.fraser@apple.com>
624 Remove ENABLE_PLUGIN_PROXY_FOR_VIDEO
625 https://bugs.webkit.org/show_bug.cgi?id=132396
627 Reviewed by Eric Carlson.
629 Remove ENABLE_PLUGIN_PROXY_FOR_VIDEO and related code.
631 * Configurations/FeatureDefines.xcconfig:
632 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
633 (WebKit::WebFrameLoaderClient::createMediaPlayerProxyPlugin): Deleted.
634 (WebKit::WebFrameLoaderClient::hideMediaPlayerProxyPlugin): Deleted.
635 (WebKit::WebFrameLoaderClient::showMediaPlayerProxyPlugin): Deleted.
636 * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
637 * WebProcess/WebPage/WebPage.cpp:
638 (WebKit::WebPage::updatePreferences):
640 2014-04-30 Brady Eidson <beidson@apple.com>
642 If there are no services available, do not show the service controls UI
643 <rdar://problem/16735665> and https://bugs.webkit.org/show_bug.cgi?id=132410
645 Reviewed by Tim Horton.
647 Add a lightweight class that lazily polls the appropriate APIs for whether or not appropriate services
648 are installed and usable on the system:
649 * UIProcess/mac/ServicesController.h: Added.
650 (WebKit::ServicesController::imageServicesExist):
651 (WebKit::ServicesController::selectionServicesExist):
652 * UIProcess/mac/ServicesController.mm: Added.
653 (WebKit::ServicesController::shared):
654 (WebKit::ServicesController::ServicesController):
655 (WebKit::ServicesController::refreshExistingServices):
656 (WebKit::ServicesController::refreshExistingServicesTimerFired):
658 Add "image services exist" and "selection services exist" parameters:
659 * Shared/WebProcessCreationParameters.cpp:
660 (WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
661 (WebKit::WebProcessCreationParameters::encode):
662 (WebKit::WebProcessCreationParameters::decode):
663 * Shared/WebProcessCreationParameters.h:
665 * UIProcess/WebContext.cpp:
666 (WebKit::WebContext::createNewWebProcess):
667 (WebKit::WebContext::refreshExistingServices): Called when the context menu proxy realizes that
668 services no longer exist.
669 * UIProcess/WebContext.h:
671 Each WebProcess hangs on to its own copy of the flags for whether or not the services exist:
672 * WebProcess/WebProcess.cpp:
673 (WebKit::WebProcess::WebProcess):
674 (WebKit::WebProcess::initializeWebProcess):
675 (WebKit::WebProcess::setEnabledServices):
676 * WebProcess/WebProcess.h:
677 (WebKit::WebProcess::imageServicesExist):
678 (WebKit::WebProcess::selectionServicesExist):
680 * UIProcess/mac/WebContextMenuProxyMac.mm:
681 (WebKit::WebContextMenuProxyMac::setupServicesMenu): If the menu creation failed, the set of services
682 on the system must have changed. So ask the WebContext to refresh them.
684 * WebProcess/WebPage/SelectionOverlayController.cpp:
685 (WebKit::SelectionOverlayController::selectionRectsDidChange): If services don't exist, don't create an
686 overlay (and destroy any existing overlay!)
688 * WebProcess/WebPage/mac/SelectionOverlayControllerMac.mm:
689 (WebKit::SelectionOverlayController::drawRect): If services don't exist, don't draw, and destroy the overlay.
691 * WebProcess/WebProcess.messages.in:
692 * WebKit2.xcodeproj/project.pbxproj:
694 2014-04-30 Gavin Barraclough <baraclough@apple.com>
696 https://bugs.webkit.org/show_bug.cgi?id=132415
697 Fix snapshotting on WebKit2
699 Reviewed by Geoff Garen
701 * UIProcess/API/Cocoa/WKWebView.mm:
702 (-[WKWebView _snapshotRect:intoImageOfWidth:completionHandler:]):
703 - Use a VisibilityToken to keep the process runnable.
705 2014-04-30 Gavin Barraclough <baraclough@apple.com>
707 Fix PageVisibility on iOS
708 https://bugs.webkit.org/show_bug.cgi?id=132393
710 Rubber stamped by Tim Horton
712 * UIProcess/ios/PageClientImplIOS.mm:
713 (WebKit::PageClientImpl::isViewWindowActive):
714 (WebKit::PageClientImpl::isViewFocused):
715 (WebKit::PageClientImpl::isViewVisible):
716 (WebKit::PageClientImpl::isViewVisibleOrOccluded):
717 (WebKit::PageClientImpl::isVisuallyIdle):
718 - m_contentView -> m_webView
720 2014-04-30 Benjamin Poulain <benjamin@webkit.org>
722 [iOS][WK2] Add a SPI to exclude the extended background from some areas of WKWebView
723 https://bugs.webkit.org/show_bug.cgi?id=132406
724 <rdar://problem/16762197>
726 Reviewed by Beth Dakin.
728 Move the extended background to a separate layer bellow the UIScrollView.
730 The geometry of that layer is then changed based on ExtendedBackgroundExclusionInsets
733 * UIProcess/API/Cocoa/WKWebView.mm:
734 (-[WKWebView initWithFrame:configuration:]):
735 (-[WKWebView _updateScrollViewBackground]):
736 (-[WKWebView _frameOrBoundsChanged]):
737 (-[WKWebView _setExtendedBackgroundExclusionInsets:]):
738 (-[WKWebView _extendedBackgroundExclusionInsets]):
739 (-[WKWebView pageExtendedBackgroundColor]): Deleted.
740 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
742 2014-04-30 Simon Fraser <simon.fraser@apple.com>
744 Fix build error when building for iOS simulator.
746 * UIProcess/ios/ProcessAssertion.mm:
748 2014-04-30 Alexey Proskuryakov <ap@apple.com>
750 Move Blob.slice() implementation into BlobRegistryImpl
751 https://bugs.webkit.org/show_bug.cgi?id=132402
753 Reviewed by Anders Carlsson.
755 * NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
756 (WebKit::NetworkBlobRegistry::registerBlobURLForSlice):
757 * NetworkProcess/FileAPI/NetworkBlobRegistry.h:
758 * NetworkProcess/NetworkConnectionToWebProcess.cpp:
759 (WebKit::NetworkConnectionToWebProcess::registerBlobURLForSlice):
760 * NetworkProcess/NetworkConnectionToWebProcess.h:
761 * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
762 * WebProcess/FileAPI/BlobRegistryProxy.cpp:
763 (WebKit::BlobRegistryProxy::registerBlobURLForSlice):
764 * WebProcess/FileAPI/BlobRegistryProxy.h:
766 2014-04-30 Beth Dakin <bdakin@apple.com>
768 Phone number data detection UI is offset for iframes, pages with topContentInset
769 https://bugs.webkit.org/show_bug.cgi?id=132372
771 <rdar://problem/16651235>
773 Reviewed by Tim Horton.
775 Make the overlay an OverlayType::Document, which will keep everything relative to
776 the main Document’s coordinates.
777 * WebProcess/WebPage/TelephoneNumberOverlayController.cpp:
778 (WebKit::TelephoneNumberOverlayController::createOverlayIfNeeded):
780 Make frames work by converting to the main document’s coordinate space.
781 * WebProcess/WebPage/mac/TelephoneNumberOverlayControllerMac.mm:
782 (WebKit::TelephoneNumberOverlayController::drawRect):
784 2014-04-30 Roger Fong <roger_fong@apple.com>
786 Unreviewed. Unnecessary explicit initialization of LayoutUnit from r167985.
788 * WebProcess/WebPage/WebPage.cpp:
789 (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
790 Darin points out that I can just use “/2” instead of “/LayoutUnit(2.0)”.
792 2014-04-30 David Hyatt <hyatt@apple.com>
794 [New Multicolumn] Enable new multi-column mode
795 https://bugs.webkit.org/show_bug.cgi?id=131825
797 Reviewed by Simon Fraser.
799 * Shared/WebPreferencesStore.h:
801 2014-04-30 Brian J. Burg <burg@cs.washington.edu>
803 Clean up unnecessary methods in the BackForwardClient interface
804 https://bugs.webkit.org/show_bug.cgi?id=131637
806 Reviewed by Andreas Kling.
808 Remove stubs for iOS-specific methods in the BackForwardClient interface.
810 Construct a WebBackForwardListProxy directly, and make the WebCore page
811 own the BackForwardClient instance. Convert uses of backForward().client()
812 to accept references instead of raw pointers.
814 * WebKit2.xcodeproj/project.pbxproj:
815 * WebProcess/InjectedBundle/InjectedBundleBackForwardList.cpp:
816 (WebKit::InjectedBundleBackForwardList::clear):
817 * WebProcess/WebPage/WebBackForwardListProxy.cpp: Store a reference to
818 WebCore::Page instead of a pointer.
819 (WebKit::WebBackForwardListProxy::WebBackForwardListProxy):
820 (WebKit::WebBackForwardListProxy::create): Deleted.
821 (WebKit::WebBackForwardListProxy::addItem):
822 (WebKit::WebBackForwardListProxy::goToItem):
823 (WebKit::WebBackForwardListProxy::itemAtIndex):
824 (WebKit::WebBackForwardListProxy::backListCount):
825 (WebKit::WebBackForwardListProxy::forwardListCount):
826 (WebKit::WebBackForwardListProxy::close):
827 (WebKit::WebBackForwardListProxy::clear):
828 (WebKit::WebBackForwardListProxy::isActive):
829 * WebProcess/WebPage/WebBackForwardListProxy.h:
830 * WebProcess/WebPage/WebPage.cpp:
831 (WebKit::WebPage::WebPage):
832 * WebProcess/WebPage/ios/WebBackForwardListProxyIOS.mm: Removed.
834 2014-04-30 Gavin Barraclough <baraclough@apple.com>
836 Fix PageVisibility on iOS
837 https://bugs.webkit.org/show_bug.cgi?id=132393
839 Reviewed by Andreas Kling.
841 Currently page visibility API doesn't work correctly on WK2 iOS for a few reasons,
842 the most significant of which being that the moment a WKWebView leaves the window
843 we'll suspend the content process, which removes the possibility for any notification
844 to be delivered. This patch addresses this issue, by allowing the process to run for
845 long enough for the notification to be delivered.
847 1) Introduce a new class, ProcessThrottler, to encapsulate the process suspension logic.
848 2) WebPageProxy uses ProcessThrottler::VisibilityToken to communicate visibility to the throttler.
849 3) WebPageProxy tracks pending didUpdateViewState messages to detect when the view state update in
850 the web content process has completed.
851 4) Distiguish between 'Background' and 'Suspended' states in the ProcessAssertion.
853 * Shared/ChildProcessProxy.h:
854 - moved m_assertion to NetworkProcessProxy / WebProcessProxy.
855 * UIProcess/Network/NetworkProcessProxy.h:
857 * UIProcess/WebPageProxy.cpp:
858 (WebKit::WebPageProxy::WebPageProxy):
859 - initialize VisibilityToken state.
860 (WebKit::WebPageProxy::reattachToWebProcess):
861 - reinitialize VisibilityToken state.
862 (WebKit::WebPageProxy::viewStateDidChange):
863 - update VisibilityToken, increment m_pendingViewStateUpdates as necessary.
864 (WebKit::WebPageProxy::updateVisibilityToken):
865 - update the VisibiliyToken based on page visibility, and whether an update is still pending.
866 (WebKit::WebPageProxy::didUpdateViewState):
867 - detect when a view state change has completed in the web process, and update throttle state as necessary.
868 * UIProcess/WebPageProxy.h:
869 (WebKit::WebPageProxy::didUpdateViewState): Deleted.
871 * UIProcess/WebProcessProxy.cpp:
872 (WebKit::WebProcessProxy::WebProcessProxy):
873 - initialize m_throttler.
874 (WebKit::WebProcessProxy::didFinishLaunching):
875 - notify the PageThrottler of the new connection.
876 * UIProcess/WebProcessProxy.h:
877 (WebKit::WebProcessProxy::throttler):
879 (WebKit::WebProcessProxy::updateProcessState): Deleted.
880 - moved trottling login to ProcessThrottler.
881 * UIProcess/ios/PageClientImplIOS.h:
882 * UIProcess/ios/PageClientImplIOS.mm:
883 (WebKit::PageClientImpl::isViewWindowActive):
884 (WebKit::PageClientImpl::isViewFocused):
885 (WebKit::PageClientImpl::isViewVisible):
886 (WebKit::PageClientImpl::isViewVisibleOrOccluded):
887 - these should only be true when the view is in a window.
888 (WebKit::PageClientImpl::isVisuallyIdle):
889 - this should only be true when the view is not in a window.
890 * UIProcess/ios/ProcessAssertion.h:
891 * UIProcess/ios/ProcessAssertion.mm:
892 (WebKit::flagsForState):
893 - map from enum -> BKSAssertion flags values.
894 (WebKit::ProcessAssertion::ProcessAssertion):
895 - use flagsForState (add support for Suspended state).
896 (WebKit::ProcessAssertion::setState):
897 - use flagsForState (add support for Suspended state).
898 * UIProcess/ios/ProcessThrottler.h: Added.
899 (WebKit::ProcessThrottler::VisibilityToken::visibility):
901 (WebKit::ProcessThrottler::VisibilityToken::setVisibility):
902 - update Visibility value; update the token as necessary.
903 (WebKit::ProcessThrottler::ProcessThrottler):
904 - constructor; does not take an assention until didConnnectToProcess is called.
905 (WebKit::ProcessThrottler::visibilityToken):
906 - create a VisibilityToken.
907 (WebKit::ProcessThrottler::didConnnectToProcess):
909 (WebKit::ProcessThrottler::weakPtr):
910 - create a weak pointer, used for references from VisibilityToken to the throttler.
911 (WebKit::ProcessThrottler::assertionState):
912 - determine the correct AssertionState for the process, based on current visibility.
913 (WebKit::ProcessThrottler::updateAssertion):
914 - update assertion, called in response to visibility change.
915 * UIProcess/ios/ProcessThrottler.mm: Added.
916 (WebKit::ProcessThrottler::VisibilityToken::VisibilityToken):
918 (WebKit::ProcessThrottler::VisibilityToken::~VisibilityToken):
919 - set visibility to hidden to reset.
920 (WebKit::ProcessThrottler::VisibilityToken::hideTimerFired):
921 - automatically decay from Hiding -> Hidden on a timeout.
922 (WebKit::ProcessThrottler::VisibilityToken::setVisibilityInternal):
923 - update counters tracking visibility in ProcessThrottler.
924 * UIProcess/ios/WKContentView.mm:
925 (-[WKContentView didMoveToWindow]):
926 - This affects all view state flags, not just the 'InWindow' state.
927 If the view moves out of a window request a reply from the WebContent - we use this
928 to detect when the page visibility event has completed.
929 * UIProcess/ios/WebProcessProxyIOS.mm:
930 (WebKit::WebProcessProxy::updateProcessState): Deleted.
932 * WebKit2.xcodeproj/project.pbxproj:
935 2014-04-30 Anders Carlsson <andersca@apple.com>
937 Preemptive header fixes for when WebKit.framework is going to provide the modern API
938 https://bugs.webkit.org/show_bug.cgi?id=132394
940 Reviewed by Dan Bernstein.
942 * UIProcess/API/Cocoa/WKBrowsingContextPolicyDelegate.h:
944 Delete WKNavigationType for now. Ultimately the entire delegate should be removed.
946 * UIProcess/API/Cocoa/WKPreferences.h:
947 Add a header guard so we can avoid importing WKPreferences.h more than once.
949 * WebKit2.xcodeproj/project.pbxproj:
950 _WKScriptWorld.h should be private, not public.
951 WKScriptMessagePrivate.h and WKUserContentControllerPrivate.h should be private, not project.
953 2014-04-30 Joseph Pecoraro <pecoraro@apple.com>
955 Web Inspector: Ensure UIProcess checks in to webinspectord after spawning a WebProcess
956 https://bugs.webkit.org/show_bug.cgi?id=132389
958 Reviewed by Timothy Hatcher.
960 We aggregate WebProcess WebView's under the UIProcess. If the UIProcess
961 didn't connect to webinspectord these WebViews would have remained
962 hidden. Always have the UIProcess connect to webinspectord when it
963 spawns a WebProcess and may have a child process holding views that
964 it ultimately owns and should display under the UIProcess name.
966 * UIProcess/WebContext.cpp:
967 (WebKit::WebContext::createNewWebProcess):
969 2014-04-30 Zalan Bujtas <zalan@apple.com>
971 [iOS]Subpixel rendering: Extra line of pixels next to the YouTube loading indicator.
972 https://bugs.webkit.org/show_bug.cgi?id=132391
974 Reviewed by Simon Fraser.
976 CG and GraphicsContext clipping should use the same coordinates. Snapping either one
977 while leaving the other unsnapped results in clipping mismatch and that may produce
982 * Shared/mac/RemoteLayerBackingStore.mm:
983 (WebKit::RemoteLayerBackingStore::drawInContext):
985 2014-04-30 Alexey Proskuryakov <ap@apple.com>
987 https://bugs.webkit.org/show_bug.cgi?id=132363
988 Make Blob RawData immutable
990 Reviewed by Anders Carlsson.
992 * Shared/FileAPI/BlobRegistrationData.cpp: (WebKit::BlobRegistrationData::decode):
993 Create RawData in one step.
995 2014-04-30 Brady Eidson <beidson@apple.com>
997 Followup to: Handle selection services menu.
998 <rdar://problem/16727798> and https://bugs.webkit.org/show_bug.cgi?id=132362
1000 * UIProcess/mac/WebContextMenuProxyMac.mm:
1001 (WebKit::WebContextMenuProxyMac::setupServicesMenu): Remove an ASSERT from previous version of the patch
1002 that landed. I’d forgotten to add this stray change to my staging area.
1004 2014-04-30 Manuel Rego Casasnovas <rego@igalia.com>
1006 [CSS Grid Layout] Enable runtime feature by default
1007 https://bugs.webkit.org/show_bug.cgi?id=132189
1009 Reviewed by Benjamin Poulain.
1011 * Shared/WebPreferencesStore.h: Remove unneeded changes that
1012 enable/disable the runtime feature depending on the compilation flag.
1013 And set it to true by default.
1014 * UIProcess/gtk/ExperimentalFeatures.cpp: Set it to true by default.
1016 2014-04-30 Roger Fong <roger_fong@apple.com>
1018 Unreviewed. Wrong units used in offset calculation from r167961.
1020 * WebProcess/WebPage/WebPage.cpp:
1021 (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
1022 I accidentally mixed and matches LayoutUnits with Ints in offset calculation here.
1023 It should all just be in LayoutUnits.
1025 2014-04-29 Benjamin Poulain <bpoulain@apple.com>
1027 [iOS][WK2] When pageScaleFactor * deviceScaleFactor = 1, the tile grid is completely messed up
1028 https://bugs.webkit.org/show_bug.cgi?id=132368
1030 Reviewed by Simon Fraser.
1032 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
1033 (WebKit::PlatformCALayerRemote::PlatformCALayerRemote):
1034 PlatformCALayerRemote always initialized the content scale to 1. Since contentsScale is supposed to reflect
1035 zoomScale * deviceScaleFactor, the value should be 2.
1037 This was causing bugs whenever the page scale factor was 1/2 on retina device (device scale factor = 2).
1039 When the page is initialized, GraphicsLayerCA::updateContentsScale(0.5) computes a contentsScale of 1. There is an early
1040 return on if (contentsScale == m_layer->contentsScale()). Since PlatformCALayerRemote->contentsScale() was incorreclty
1041 returning one, we were leaving the tile backing unmodified.
1043 Later, when the transaction is commited, the tile backing would still be default initialized and would render everything
1046 2014-04-29 Eric Carlson <eric.carlson@apple.com>
1048 [Mac] tag the video layers with descriptive name to aid debugging
1049 https://bugs.webkit.org/show_bug.cgi?id=132371
1051 Reviewed by Darin Adler.
1053 * WebProcess/ios/WebVideoFullscreenManager.mm:
1054 (WebKit::WebVideoFullscreenManager::enterFullscreenForNode): Set the
1055 fullscreen host layer name in a debug build.
1057 2014-04-29 Brady Eidson <beidson@apple.com>
1059 Handle selection services menu.
1060 <rdar://problem/16727798> and https://bugs.webkit.org/show_bug.cgi?id=132362
1062 Reviewed by Tim Horton.
1064 Add members for the relevant info for showing a service menu for a selection:
1065 * Shared/ContextMenuContextData.cpp:
1066 (WebKit::ContextMenuContextData::ContextMenuContextData):
1067 (WebKit::ContextMenuContextData::controlledDataIsEditable):
1068 * Shared/ContextMenuContextData.h:
1069 (WebKit::ContextMenuContextData::ContextMenuContextData):
1070 (WebKit::ContextMenuContextData::controlledSelectionData):
1071 (WebKit::ContextMenuContextData::needsServicesMenu):
1073 * UIProcess/WebPageProxy.h:
1074 * UIProcess/WebPageProxy.messages.in:
1075 * UIProcess/mac/WebPageProxyMac.mm:
1076 (WebKit::WebPageProxy::replaceSelectionWithPasteboardData): Changed to allow for multiple types on the overridden pasteboard.
1077 (WebKit::WebPageProxy::showSelectionServiceMenu):
1079 Update the services menu code to know the difference between an image service and a selection service:
1080 * UIProcess/mac/WebContextMenuProxyMac.h:
1081 * UIProcess/mac/WebContextMenuProxyMac.mm:
1082 (-[WKSharingServicePickerDelegate sharingServicePicker:sharingServicesForItems:mask:proposedSharingServices:]):
1083 (-[WKSharingServicePickerDelegate sharingService:willShareItems:]):
1084 (-[WKSharingServicePickerDelegate sharingService:didShareItems:]):
1085 (WebKit::WebContextMenuProxyMac::contextMenuItemSelected):
1086 (WebKit::WebContextMenuProxyMac::setupServicesMenu):
1087 (WebKit::WebContextMenuProxyMac::clearServicesMenu):
1088 (WebKit::WebContextMenuProxyMac::populate):
1089 (WebKit::WebContextMenuProxyMac::showContextMenu):
1090 (WebKit::WebContextMenuProxyMac::setupImageServicesMenu): Deleted.
1091 (WebKit::WebContextMenuProxyMac::clearImageServicesMenu): Deleted.
1093 * WebProcess/WebCoreSupport/WebPasteboardOverrides.cpp:
1094 (WebKit::WebPasteboardOverrides::getDataForOverride):
1096 * WebProcess/WebPage/WebPage.h:
1097 * WebProcess/WebPage/WebPage.messages.in:
1098 * WebProcess/WebPage/mac/WebPageMac.mm:
1099 (WebKit::WebPage::replaceSelectionWithPasteboardData): Changed to allow for multiple types on the overridden pasteboard.
1100 (WebKit::WebPage::handleSelectionServiceClick): Pass the relevant selection data through to the UIProcess as RTFD data.
1102 * WebProcess/WebPage/mac/SelectionOverlayControllerMac.mm:
1103 (WebKit::SelectionOverlayController::handleClick): Notify the WebPage of the click.
1105 2014-04-29 Dan Bernstein <mitz@apple.com>
1107 <rdar://problem/16745596> [Cocoa] Crash when invoking a method with an unsigned parameter on a remote object
1108 https://bugs.webkit.org/show_bug.cgi?id=132366
1110 Reviewed by Anders Carlsson.
1112 * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
1113 (encodeInvocation): Handle the 'I' type code. Interpret the 'q' and 'Q' type codes in an
1114 architecture-independent manner.
1115 (decodeInvocationArguments): Ditto.
1117 2014-04-29 Roger Fong <roger_fong@apple.com>
1119 Don't immediately snapshot plugin to allow for proper dominant plugin detection.
1120 https://bugs.webkit.org/show_bug.cgi?id=132294.
1121 <rdar://problem/16745679>
1123 Reviewed by Dean Jackson.
1125 * WebProcess/Plugins/PluginView.cpp:
1126 (WebKit::PluginView::didInitializePlugin):
1127 Instead of immediately setting the display state to DisplaySnapshot,
1128 put it on a timer to let the page fully layout and get hit test properly.
1130 2014-04-28 Roger Fong <roger_fong@apple.com>
1132 Plugins hidden by images should autoplay.
1133 https://bugs.webkit.org/show_bug.cgi?id=132222.
1134 <rdar://problem/16653536>
1136 Reviewed by Jon Lee and Darin Adler.
1138 * WebProcess/WebPage/WebPage.cpp:
1139 (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
1140 If the image on top of the plugin is similarly sized and similarly positioned as the plugin rect,
1141 set the plugin to autoplay. This is assuming that the previous snapshot checks have passed as well.
1143 2014-04-29 Filip Pizlo <fpizlo@apple.com>
1145 Use LLVM as a backend for the fourth-tier DFG JIT (a.k.a. the FTL JIT)
1146 https://bugs.webkit.org/show_bug.cgi?id=112840
1148 Rubber stamped by Geoffrey Garen.
1150 * Configurations/FeatureDefines.xcconfig:
1152 2014-04-29 Brady Eidson <beidson@apple.com>
1154 Change Image Controls replacement to use selection and paste
1155 <rdar://problem/16302722> and https://bugs.webkit.org/show_bug.cgi?id=131992
1157 Reviewed by Tim Horton.
1159 Add a "pasteboard override" mechanism which allows WebKit to keep pasteboard content local
1160 to the WebProcess and access it there without having to message up to the UI process:
1161 * WebProcess/WebCoreSupport/WebPasteboardOverrides.cpp: Added.
1162 (WebKit::WebPasteboardOverrides::sharedPasteboardOverrides):
1163 (WebKit::WebPasteboardOverrides::WebPasteboardOverrides):
1164 (WebKit::WebPasteboardOverrides::addOverride):
1165 (WebKit::WebPasteboardOverrides::removeOverride):
1166 (WebKit::WebPasteboardOverrides::overriddenTypes):
1167 (WebKit::WebPasteboardOverrides::getDataForOverride):
1168 * WebProcess/WebCoreSupport/WebPasteboardOverrides.h: Added.
1170 Change the pasteboard strategy to consult the pasteboard overrides before consulting the native pasteboard:
1171 * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1172 (WebKit::WebPlatformStrategies::getTypes):
1173 (WebKit::WebPlatformStrategies::bufferForType):
1175 Add "replaceSelectionWithPasteboardData" which uses the new pasteboard overrides mechanism
1176 and then has WebCore perform the replacement:
1177 * WebProcess/WebPage/WebPage.h:
1178 * WebProcess/WebPage/WebPage.messages.in:
1179 * WebProcess/WebPage/mac/WebPageMac.mm:
1180 (WebKit::replaceSelectionPasteboardName):
1181 (WebKit::WebPage::replaceSelectionWithPasteboardData):
1183 * UIProcess/mac/WebPageProxyMac.mm:
1184 (WebKit::WebPageProxy::replaceSelectionWithPasteboardData):
1186 * UIProcess/mac/WebContextMenuProxyMac.h:
1187 (WebKit::WebContextMenuProxyMac::page):
1188 * UIProcess/mac/WebContextMenuProxyMac.mm:
1189 (-[WKSharingServicePickerDelegate sharingService:didShareItems:]): Use "replaceSelectionWithPasteboardData".
1190 (WebKit::WebContextMenuProxyMac::WebContextMenuProxyMac):
1191 (WebKit::WebContextMenuProxyMac::replaceControlledImage): Deleted.
1193 Remain other remnants of "replaceControlledImage":
1194 * UIProcess/WebPageProxy.cpp:
1195 (WebKit::WebPageProxy::replaceControlledImage): Deleted.
1196 * UIProcess/WebPageProxy.h:
1197 * WebProcess/WebPage/WebContextMenu.cpp:
1198 (WebKit::WebContextMenu::replaceControlledImage): Deleted.
1199 * WebProcess/WebPage/WebContextMenu.h:
1200 * WebProcess/WebPage/WebPage.cpp:
1201 (WebKit::WebPage::replaceControlledImage): Deleted.
1203 * WebKit2.xcodeproj/project.pbxproj:
1205 2014-04-29 Tim Horton <timothy_horton@apple.com>
1209 * DatabaseProcess/ios/DatabaseProcessIOS.mm:
1211 2014-04-29 Alexey Proskuryakov <ap@apple.com>
1213 [WK2] DatabaseProcess should be sandboxed
1214 https://bugs.webkit.org/show_bug.cgi?id=132324
1215 <rdar://problem/15961708>
1217 Reviewed by Darin Adler.
1219 * Configurations/WebKit2.xcconfig: Added the profile to the list of files skipped
1222 * DatabaseProcess/DatabaseProcess.cpp: (WebKit::DatabaseProcess::initializeDatabaseProcess):
1223 Consume a sandbox extension for IndexedDB directory (which we get with initialization
1224 message after entering sandbox).
1226 * DatabaseProcess/ios: Added.
1227 * DatabaseProcess/ios/DatabaseProcessIOS.mm: Copied from Source/WebKit2/DatabaseProcess/mac/DatabaseProcessMac.mm.
1228 Separated from Mac version to match how other processes are implemented.
1230 * DatabaseProcess/mac/DatabaseProcessMac.mm: (WebKit::DatabaseProcess::initializeProcessName):
1233 * DatabaseProcess/mac/com.apple.WebKit.Databases.sb.in: Added.
1235 * DerivedSources.make: Generate the profile from .sb.in.
1237 * Shared/Databases/DatabaseProcessCreationParameters.cpp:
1238 (WebKit::DatabaseProcessCreationParameters::encode):
1239 (WebKit::DatabaseProcessCreationParameters::decode):
1240 * Shared/Databases/DatabaseProcessCreationParameters.h:
1241 Added a sandbox extension for indexedDatabaseDirectory.
1243 * Shared/SecurityOriginData.h: Added an unrelated FIXME.
1245 * UIProcess/WebContext.cpp: (WebKit::WebContext::ensureDatabaseProcess): Create
1246 a sandbox extension for indexedDatabaseDirectory.
1248 * WebKit2.xcodeproj/project.pbxproj: Added new files.
1250 2014-04-28 Andy Estes <aestes@apple.com>
1252 [iOS] Introduce -didNotHandleTapAsClickAtPoint: to WKUIDelegatePrivate
1253 https://bugs.webkit.org/show_bug.cgi?id=132316
1255 Reviewed by Darin Adler.
1257 One WebKit2 client is interested to know if a tap was not handled by an element that responds to clicks.
1258 Introduce a new, private WKUIDelegate method telling it that a tap at a location was not handled as a click on
1261 * UIProcess/API/APIUIClient.h:
1262 (API::UIClient::didNotHandleTapAsClick):
1263 * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
1264 * UIProcess/Cocoa/UIDelegate.h:
1265 * UIProcess/Cocoa/UIDelegate.mm:
1266 (WebKit::UIDelegate::setDelegate):
1267 (WebKit::UIDelegate::UIClient::didNotHandleTapAsClick):
1268 * UIProcess/WebPageProxy.h:
1269 * UIProcess/WebPageProxy.messages.in:
1270 * UIProcess/ios/WebPageProxyIOS.mm:
1271 (WebKit::WebPageProxy::didNotHandleTapAsClick):
1272 * WebProcess/WebPage/ios/WebPageIOS.mm:
1273 (WebKit::WebPage::handleTap): Sent Messages::WebPageProxy::DidNotHandleTapAsClick if the tap wasn't handled, no
1274 node responded to the click event, or the responding node wasn't an element.
1276 2014-04-29 Zan Dobersek <zdobersek@igalia.com>
1278 [GTK][WK2] Avoid Vector copies in WebViewBaseInputMethodFilter::setPreedit()
1279 https://bugs.webkit.org/show_bug.cgi?id=132323
1281 Reviewed by Carlos Garcia Campos.
1283 * UIProcess/API/gtk/WebViewBaseInputMethodFilter.cpp:
1284 (WebKit::WebViewBaseInputMethodFilter::setPreedit): Inline the Vector object construction into
1285 the WebPageProxy::setComposition() call to avoid extra Vector copies and moves.
1287 2014-04-28 Dan Bernstein <mitz@apple.com>
1289 <rdar://problem/16750708> REGRESSION (r159358): Crash in InjectedBundleHitTestResult::frame
1290 https://bugs.webkit.org/show_bug.cgi?id=132318
1292 Reviewed by Andy Estes.
1294 * UIProcess/Cocoa/NavigationState.mm:
1295 (WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction): Fixed a typo: set
1296 the source frame, not the destination frame.
1298 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1299 (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Changed to get the
1300 frame for the action not from a hit test result, because some link activation actions are
1301 not mouse events, but rather from the event’s target.
1303 2014-04-28 Benjamin Poulain <bpoulain@apple.com>
1305 [iOS][WK2] Restore the scroll position and scale from the HistoryItem (mostly)
1306 https://bugs.webkit.org/show_bug.cgi?id=132307
1307 <rdar://problem/16031704>
1309 Reviewed by Simon Fraser.
1311 Restore the scroll position and scale on back-forward by restoring the values from HistoryItem.
1312 This covers the common cases, see <rdar://problem/16031704>.
1314 * UIProcess/API/Cocoa/WKWebView.mm:
1315 (-[WKWebView _didCommitLayerTree:WebKit::]):
1316 (-[WKWebView _didCommitLoadForMainFrame]): Deleted.
1317 * UIProcess/API/Cocoa/WKWebViewInternal.h:
1318 * UIProcess/ios/WKContentView.mm:
1319 (-[WKContentView _didCommitLoadForMainFrame]):
1320 Get rid of the old code restoring the scroll position. This is now done by the WebProcess.
1322 * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
1323 (WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):
1324 Update the scrolling tree after invoking didCommitLayerTree() on the WebPageProxy.
1326 WKContentView and WKWebView states are updated in response to didCommitLayerTree(), the content size
1327 and scale in particular are set there.
1329 After that, the content size/scale is in the same state as the layerTree update, and we can scroll
1330 the content as needed.
1332 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1333 * WebProcess/WebCoreSupport/ios/WebFrameLoaderClientIOS.mm:
1334 (WebKit::WebFrameLoaderClient::restoreViewState):
1335 iOS WebKit1 uses a custom restoreViewState(), do the same for WebKit2 since the generic code is #ifdefed out.
1336 This is also necessary for the main frame's state update.
1338 * WebProcess/WebPage/WebPage.h:
1339 * WebProcess/WebPage/ios/WebPageIOS.mm:
1340 (WebKit::WebPage::restorePageState):
1341 Restore the scale and position of the main frame. For now, we assume m_userHasChangedPageScaleFactor is set otherwise
1342 the initial-scale would override the restored value. We will need to fix that, the value should probably be saved with
1345 2014-04-28 Benjamin Poulain <bpoulain@apple.com>
1347 [iOS][WK2] iOS fix after r167867
1348 https://bugs.webkit.org/show_bug.cgi?id=132302
1350 Reviewed by Simon Fraser.
1352 iOS Touch Points uses "phase" for describing the touch points state for historical reasons.
1353 This patch adds state() as a synonym for phase, and revert r167893.
1355 * Shared/WebEvent.h:
1356 (WebKit::WebPlatformTouchPoint::state):
1357 * UIProcess/WebPageProxy.cpp:
1358 (WebKit::areAllTouchPointsReleased):
1360 2014-04-28 Andy Estes <aestes@apple.com>
1362 Fix a transcription error from r167901.
1364 When addressing Darin's review feedback, I moved the iteration of dataArray from
1365 QuickLookDocumentData::append() to WebQuickLookHandleClient::didReceiveDataArray(),
1366 but I forgot to update the context argument to CFArrayApplyFunction() accordingly.
1368 * WebProcess/WebCoreSupport/ios/WebQuickLookHandleClient.cpp:
1369 (WebKit::WebQuickLookHandleClient::didReceiveDataArray):
1371 2014-04-28 Enrica Casucci <enrica@apple.com>
1373 [WK2 iOS] Need to show title in the action sheet for images not inside an anchor element.
1374 https://bugs.webkit.org/show_bug.cgi?id=132304
1375 <rdar://problem/16535227>
1377 Reviewed by Benjamin Poulain.
1379 If the image in not inside an anchor tag, we must use the title attribute as
1380 title for the action sheet.
1382 * UIProcess/ios/WKActionSheetAssistant.mm:
1383 (-[WKActionSheetAssistant _createSheetWithElementActions:showLinkTitle:]):
1385 2014-04-28 Tim Horton <timothy_horton@apple.com>
1387 WebKit2 View Gestures (Swipe): Discard snapshots made with a different view size/pixel density
1388 https://bugs.webkit.org/show_bug.cgi?id=132115
1390 Reviewed by Simon Fraser.
1392 We shouldn't try to use snapshots if they no longer match the destination view size.
1393 To do this, we need an accurate understanding of the topContentInset, both for the Web view,
1394 and for any custom views, because we don't want to include the inset area in the snapshot,
1395 and we don't want to reject snapshots that differ from the current view only because they have an inset or not.
1397 * UIProcess/API/Cocoa/WKViewPrivate.h:
1398 * UIProcess/API/mac/WKView.mm:
1399 (-[WKView _takeViewSnapshot]):
1400 (-[WKView _setCustomSwipeViewsTopContentInset:]):
1401 Add and plumb through a topContentInset property to apply to the custom swipe views.
1402 For simplicitly's sake in the multi-view case, it is applied in window coordinates,
1403 so clients will have to do conversions if necessary.
1404 Don't include the top content inset in the snapshot that is taken.
1406 * UIProcess/mac/ViewGestureController.h:
1407 (WebKit::ViewGestureController::setCustomSwipeViewsTopContentInset):
1408 * UIProcess/mac/ViewGestureControllerMac.mm:
1409 (WebKit::ViewGestureController::ViewGestureController):
1410 (WebKit::ViewGestureController::windowRelativeBoundsForCustomSwipeViews):
1411 Apply the aforementioned custom swipe view top content inset.
1413 (WebKit::ViewGestureController::determineSnapshotLayerParent):
1414 (WebKit::ViewGestureController::determineLayerAdjacentToSnapshotForParent):
1415 Factor these out of beginSwipeGesture.
1417 (WebKit::ViewGestureController::retrieveSnapshotForItem):
1418 Don't return a snapshot if the current deviceScaleFactor doesn't match that
1419 at which the snapshot was taken, or if the size of the snapshot doesn't match
1420 the unobscured part of the snapshot layer (the layer's size sans top content inset).
1422 (WebKit::layerGeometryFlippedToRoot): Added.
1423 Determine whether geometry flipping occurs between a layer and the root of the tree it is in.
1425 (WebKit::ViewGestureController::applyDebuggingPropertiesToSwipeViews):
1426 Factor out debugging layer properties, and add some borders and backgrounds to our layers.
1427 I switched to invert instead of blur because blur makes the borders hard to use.
1429 (WebKit::ViewGestureController::beginSwipeGesture):
1430 Add an additional layer, the swipeLayer, which is the parent of the swipeSnapshotLayer.
1431 We use this layer to compensate for geometry flipping, since we don't necessarily
1432 know the structure of the layer tree ahead of time when inserting snapshots into the
1433 client's layer tree, in the custom swipe view case.
1434 The swipe layer is always the full size of the view, including topContentInset, and
1435 has a white background in order to fill in that space. The snapshot layer is the size
1436 of the view *excluding* the topContentInset, which should match the size of the snapshot image
1437 itself (and we reject the image and just paint white if this is not the case).
1439 (WebKit::ViewGestureController::handleSwipeGesture):
1440 (WebKit::ViewGestureController::removeSwipeSnapshot):
1441 Move and remove the new swipeLayer.
1443 * UIProcess/mac/ViewSnapshotStore.h:
1444 * UIProcess/mac/ViewSnapshotStore.mm:
1445 (WebKit::ViewSnapshotStore::recordSnapshot):
1446 Store the deviceScaleFactor at the time the snapshot was taken.
1447 Fix a bug where the count of snapshots with live images was too high
1448 because we were failing to decrement it when replacing a snapshot of
1449 an existing item with a fresh one.
1451 2014-04-28 Enrica Casucci <enrica@apple.com>
1453 WK2 iOS: crash when handling a synthetic keyboard event.
1454 https://bugs.webkit.org/show_bug.cgi?id=132296
1455 <rdar://problem/16469726>
1457 Reviewed by Benjamin Poulain.
1459 Adding a null check, since synthetic keyboard events do not
1460 have a corresponding platform event. We already do this on OS X.
1462 * WebProcess/WebPage/ios/WebPageIOS.mm:
1463 (WebKit::WebPage::handleEditingKeyboardEvent):
1465 2014-04-24 Andy Estes <aestes@apple.com>
1467 [iOS] Implement WebQuickLookHandleClient for WebKit2
1468 https://bugs.webkit.org/show_bug.cgi?id=132157
1470 Reviewed by Darin Adler.
1472 * Shared/API/Cocoa/_WKNSFileManagerExtras.h: Added.
1473 * Shared/API/Cocoa/_WKNSFileManagerExtras.mm: Added.
1474 (+[NSFileManager _web_createTemporaryFileForQuickLook:]): Called WebCore::createTemporaryFileForQuickLook().
1475 * Shared/ios/QuickLookDocumentData.cpp: Added.
1476 (WebKit::QuickLookDocumentData::QuickLookDocumentData):
1477 (WebKit::QuickLookDocumentData::append): Appened each CFDataRef to m_data and added their sizes to m_size.
1478 (WebKit::QuickLookDocumentData::decodedData): Returned the combined CFDataRef created by decode().
1479 Named this method 'decodedData' to indicate that it should only be called on objects populated by decode().
1480 (WebKit::QuickLookDocumentData::clear): Cleared m_data and reset m_size to 0.
1481 (WebKit::QuickLookDocumentData::encode): Implemented a custom encoding function to avoid having to combine
1482 m_data into contiguous memory at encoding time. Encoded m_size then sequentially encoded each member of m_data.
1483 (WebKit::QuickLookDocumentData::decode): Decoded the byte stream into a single CFDataRef. Eagerly copied the
1484 decoded data rather than using a DataReference since we know this will outlive the decoder.
1485 * Shared/ios/QuickLookDocumentData.h: Added.
1486 * UIProcess/API/APILoaderClient.h:
1487 (API::LoaderClient::didStartLoadForQuickLookDocumentInMainFrame):
1488 (API::LoaderClient::didFinishLoadForQuickLookDocumentInMainFrame):
1489 * UIProcess/API/Cocoa/WKNavigationDelegatePrivate.h:
1490 * UIProcess/Cocoa/NavigationState.h:
1491 * UIProcess/Cocoa/NavigationState.mm:
1492 (WebKit::NavigationState::setNavigationDelegate):
1493 (WebKit::NavigationState::LoaderClient::didStartLoadForQuickLookDocumentInMainFrame):
1494 (WebKit::NavigationState::LoaderClient::didFinishLoadForQuickLookDocumentInMainFrame):
1495 * UIProcess/WebPageProxy.h:
1496 * UIProcess/WebPageProxy.messages.in:
1497 * UIProcess/ios/WebPageProxyIOS.mm:
1498 (WebKit::WebPageProxy::didStartLoadForQuickLookDocumentInMainFrame):
1499 (WebKit::WebPageProxy::didFinishLoadForQuickLookDocumentInMainFrame):
1500 * WebKit2.xcodeproj/project.pbxproj:
1501 * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
1502 * WebProcess/WebCoreSupport/ios/WebFrameLoaderClientIOS.mm:
1503 (WebKit::WebFrameLoaderClient::didCreateQuickLookHandle):
1504 * WebProcess/WebCoreSupport/ios/WebQuickLookHandleClient.cpp: Added.
1505 (WebKit::WebQuickLookHandleClient::WebQuickLookHandleClient): Sent DidStartLoadForQuickLookDocumentInMainFrame
1507 (WebKit::WebQuickLookHandleClient::didReceiveDataArray): Appended dataArray to m_data.
1508 (WebKit::WebQuickLookHandleClient::didFinishLoading): Sent DidFinishLoadForQuickLookDocumentInMainFrame to
1509 WebPageProxy and then cleared m_data.
1510 (WebKit::WebQuickLookHandleClient::didFail): Cleared m_data.
1511 * WebProcess/WebCoreSupport/ios/WebQuickLookHandleClient.h: Added.
1512 (WebKit::WebQuickLookHandleClient::create):
1514 2014-04-28 Brady Eidson <beidson@apple.com>
1516 Hide service controls for selection behind a runtime switch
1517 <rdar://problem/16736616> and https://bugs.webkit.org/show_bug.cgi?id=132291
1519 Reviewed by Tim Horton.
1521 * Shared/WebPreferencesStore.h:
1523 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1524 (WebKit::WebEditorClient::selectionRectsDidChange): Do nothing if the UI is disabled.
1526 * WebProcess/WebPage/WebPage.cpp:
1527 (WebKit::WebPage::WebPage):
1528 (WebKit::WebPage::updatePreferences):
1530 * WebProcess/WebPage/WebPage.h:
1531 (WebKit::WebPage::serviceControlsEnabled):
1533 2014-04-28 Commit Queue <commit-queue@webkit.org>
1535 Unreviewed, rolling out r167853.
1536 https://bugs.webkit.org/show_bug.cgi?id=132288
1538 caused crashes+timeouts+layout test failures described in the
1539 bug (Requested by thorton on #webkit).
1543 "Coalesce responses on network process side"
1544 https://bugs.webkit.org/show_bug.cgi?id=132229
1545 http://trac.webkit.org/changeset/167853
1547 2014-04-28 Simon Fraser <simon.fraser@apple.com>
1551 * UIProcess/WebPageProxy.cpp:
1552 (WebKit::areAllTouchPointsReleased):
1554 2014-04-24 Simon Fraser <simon.fraser@apple.com>
1556 [iOS WK2] Make subview rebuilding more incremental
1557 https://bugs.webkit.org/show_bug.cgi?id=132162
1558 <rdar://problem/16718916>
1560 Reviewed by Sam Weinig.
1562 Previously we did bulk replacement of subviews, but that triggers
1563 UIKit to send spurious will/DidMoveToWindow messages, which can
1564 interfere with UIScrollView scrolling.
1566 Make _web_setSubviews more incremental, only removing
1567 deleted subviews, adding new ones, and moving existing ones
1568 into the correct order.
1570 * Shared/mac/RemoteLayerTreePropertyApplier.mm:
1571 (-[UIView _web_setSubviews:]):
1573 2014-04-24 Simon Fraser <simon.fraser@apple.com>
1575 [iOS WK2] flickery scrolling with overflow-scrolling:touch
1576 https://bugs.webkit.org/show_bug.cgi?id=132150
1577 <rdar://problem/16683006>
1579 Reviewed by Tim Horton.
1581 Maintain a flag that tells us if the user is interacting
1582 with the UIScrollView, and while set, don't clobber the contentOffset
1583 via scrolling tree updates.
1585 * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
1586 (-[WKOverflowScrollViewDelegate initWithScrollingTreeNode:WebKit::]):
1587 (-[WKOverflowScrollViewDelegate scrollViewWillBeginDragging:]):
1588 (-[WKOverflowScrollViewDelegate scrollViewDidEndDragging:willDecelerate:]):
1589 (-[WKOverflowScrollViewDelegate scrollViewDidEndDecelerating:]): We need this one,
1590 not scrollViewDidEndScrollingAnimation:, to detect the end of decleration.
1591 (WebKit::ScrollingTreeOverflowScrollingNodeIOS::updateAfterChildren):
1592 (-[WKOverflowScrollViewDelegate scrollViewDidEndScrollingAnimation:]): Deleted.
1594 2014-04-28 Krzysztof Wolanski <k.wolanski@samsung.com>
1596 [X11] Add missing case for mime type application/x-webkit-test-netscape
1597 https://bugs.webkit.org/show_bug.cgi?id=132278
1599 Reviewed by Darin Adler.
1601 Case for x-webkit-test-netscape has been omitted along with r167759.
1603 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1604 (WebKit::NetscapePlugin::initialize):
1606 2014-04-28 Zan Dobersek <zdobersek@igalia.com>
1608 [WK2][X11] NetscapePluginModule::scanPlugin() should write UTF-8 strings to stdout
1609 https://bugs.webkit.org/show_bug.cgi?id=132245
1611 Reviewed by Carlos Garcia Campos.
1613 NetscapePluginModule::scanPlugin(), in the helper writeLine function, takes each character
1614 of the given string and writes it out as a UChar, doing two fputc calls for each byte of the
1617 This fails badly with characters with integer value less than 256 as the most significant byte
1618 of the UChar is written out as a null character. This effectively chops the output that's gathered
1619 in the UIProcess and is parsed in PluginProcessProxy::scanPlugin().
1621 To avoid all this, the UTF-8 encoding of the string is written out in the PluginProcess, and
1622 String::fromUTF8() is called in the UIProcess to properly decode the received string.
1624 * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
1625 (WebKit::writeCharacter):
1626 (WebKit::writeLine):
1627 (WebKit::writeByte): Deleted.
1628 * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
1629 (WebKit::PluginProcessProxy::scanPlugin):
1631 2014-04-28 Zan Dobersek <zdobersek@igalia.com>
1633 [GTK][WK2] Missing return statement in webkit_plugin_get_description()
1634 https://bugs.webkit.org/show_bug.cgi?id=132263
1636 Reviewed by Carlos Garcia Campos.
1638 * UIProcess/API/gtk/WebKitPlugin.cpp:
1639 (webkit_plugin_get_description): Actually return the data of the cached
1640 plugin description CString.
1642 2014-04-28 Carlos Garcia Campos <cgarcia@igalia.com>
1644 [GTK] Crash in debug build with removing windowed plugin child widgets from the view
1645 https://bugs.webkit.org/show_bug.cgi?id=132252
1647 Reviewed by Philippe Normand.
1649 It crashes due to an assert in HashTable that checks the iterators
1650 validity. The problem is that we are iterating the children map
1651 and the callback called on every iteration might modify the map,
1652 making the iterators invalid. This happens when the WebView is
1653 destroyed, GtkContainer calls gtk_container_foreach() with
1654 gtk_widget_destroy as callback. When a widget inside a container
1655 is destroyed, it's removed from the container, and in our case,
1656 the child widget is removed from the map. This fixes several
1657 crashes when running layout tests in debug bot.
1659 * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1660 (webkitWebViewBaseContainerForall): Use copyKeysToVector() instead
1661 of using a range iterator for the map keys and check in every
1662 iteration that the child widget from the keys vector is still
1663 present in the map before calling the callback.
1665 2014-04-28 Carlos Garcia Campos <cgarcia@igalia.com>
1667 [GTK] GObject introspection links to installed libs when using jhbuild
1668 https://bugs.webkit.org/show_bug.cgi?id=132220
1670 Reviewed by Martin Robinson.
1672 The problem is that gobject-introspection is linking the temporary
1673 binaries adding the library paths present LDFLAGS environment
1674 variable first, taking precedence over the libraries in the build
1675 dir. Since the libraries paths of the dependencies are already
1676 correctly deduced by gobject-introspection using ldd, we can
1677 just unset the LDFLAGS variable before calling g-ir-scanner to
1678 make sure the libraries in the build dir take predence.
1680 * PlatformGTK.cmake:
1682 2014-04-27 Tim Horton <timothy_horton@apple.com>
1684 REGRESSION (r164702): Double tap doesn't stay under the new element once the animation finishes
1685 https://bugs.webkit.org/show_bug.cgi?id=132239
1686 <rdar://problem/16192842>
1688 Reviewed by Darin Adler.
1690 * WebProcess/WebPage/WebPage.cpp:
1691 (WebKit::WebPage::scalePage):
1692 The change in r167864 broke iOS animated resize, because it was depending on
1693 the dynamic size update code not running if the scale wasn't going to change.
1694 So, as a band-aid we should bail from doing that work if the scales aren't different.
1695 In the long term we should try to untangle this code and make it less platform dependent.
1697 2014-04-27 Eunmi Lee <eunmi15.lee@samsung.com>
1699 TouchEvent is not handled after releasing any point among touched points.
1700 https://bugs.webkit.org/show_bug.cgi?id=132043
1702 Reviewed by Benjamin Poulain.
1704 Handle TouchEvent until all touched points are released by setting
1705 trackingTouchEvents variable to false when all points are released.
1707 * UIProcess/WebPageProxy.cpp:
1708 (WebKit::areAllTouchPointsReleased):
1709 (WebKit::WebPageProxy::handleTouchEventSynchronously):
1710 (WebKit::WebPageProxy::handleTouchEventAsynchronously):
1711 (WebKit::WebPageProxy::handleTouchEvent):
1713 2014-04-27 Alexey Proskuryakov <ap@apple.com>
1715 Don't use DispatchMessageEvenWhenWaitingForSyncReply for messages from NetworkProcess
1716 https://bugs.webkit.org/show_bug.cgi?id=132144
1718 Reviewed by Darin Adler.
1720 * NetworkProcess/AsynchronousNetworkLoaderClient.cpp:
1721 (WebKit::AsynchronousNetworkLoaderClient::willSendRequest):
1722 (WebKit::AsynchronousNetworkLoaderClient::canAuthenticateAgainstProtectionSpace):
1723 Dont use the IPC::DispatchMessageEvenWhenWaitingForSyncReply flag. It's not needed,
1724 almost never works in NetworkProcess, but may cause trouble if it did.
1726 * NetworkProcess/NetworkConnectionToWebProcess.cpp:
1727 (WebKit::NetworkConnectionToWebProcess::NetworkConnectionToWebProcess): Removed
1728 setOnlySendMessagesAsDispatchWhenWaitingForSyncReplyWhenProcessingSuchAMessage()
1729 function call, because there are no more any messages in NetworkProcess it could affect.
1731 * Platform/IPC/Connection.cpp: (IPC::Connection::dispatchMessage): Added a FIXME
1732 for an unrelated bug Anders and myself noticed while looking into this.
1734 2014-04-27 Dan Bernstein <mitz@apple.com>
1736 [Cocoa] -[WKWebProcessPlugInController parameters] returns nil if no parameters have been set yet
1737 https://bugs.webkit.org/show_bug.cgi?id=132223
1739 Reviewed by Sam Weinig.
1741 * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
1742 (WebKit::InjectedBundle::bundleParameters): Create the WKWebProcessBundleParameters if
1745 2014-04-27 Tim Horton <timothy_horton@apple.com>
1747 REGRESSION (r164702): Double tap doesn't stay under the new element once the animation finishes
1748 https://bugs.webkit.org/show_bug.cgi?id=132239
1749 <rdar://problem/16192842>
1751 Reviewed by Sam Weinig.
1753 * WebProcess/WebPage/WebPage.cpp:
1754 (WebKit::WebPage::scalePage):
1755 The early-return added to WebPage::scalePage breaks callers who depend
1756 on being able to call scalePage() with the same scale but a different
1757 origin and having that change take effect.
1759 Page::setPageScaleFactor already has the requisite logic, so move
1760 the early return down after that call, and guard only notification
1761 of page scale changes.
1763 2014-04-25 Andy Estes <aestes@apple.com>
1765 [iOS] Stop creating a WKWebResourceQuickLookDelegate for every WebResourceLoader
1766 https://bugs.webkit.org/show_bug.cgi?id=132215
1768 Reviewed by Dan Bernstein.
1770 * WebKit2.xcodeproj/project.pbxproj:
1771 * WebProcess/Network/WebResourceLoader.cpp:
1772 (WebKit::WebResourceLoader::didReceiveResponseWithCertificateInfo): Called QuickLookHandle::create() directly.
1773 * WebProcess/Network/WebResourceLoader.h:
1774 * WebProcess/ios/WebResourceLoaderIOS.mm: Removed.
1776 2014-04-27 Sam Weinig <sam@webkit.org>
1778 [iOS WebKit2] Add support for text autosizing
1779 <rdar://problem/16545245>
1780 https://bugs.webkit.org/show_bug.cgi?id=132237
1782 Reviewed by Tim Horton.
1784 * Shared/WebPageCreationParameters.cpp:
1785 (WebKit::WebPageCreationParameters::encode):
1786 (WebKit::WebPageCreationParameters::decode):
1787 * Shared/WebPageCreationParameters.h:
1788 * UIProcess/WebPageProxy.cpp:
1789 (WebKit::WebPageProxy::creationParameters):
1790 * UIProcess/WebPageProxy.h:
1791 * UIProcess/ios/WebPageProxyIOS.mm:
1792 (WebKit::WebPageProxy::textAutosizingWidth):
1793 * WebProcess/WebPage/WebPage.cpp:
1794 (WebKit::WebPage::WebPage):
1795 Pass the text autosizing width from the UIProcess to WebProcess.
1797 2014-04-27 Tim Horton <timothy_horton@apple.com>
1799 WebKit2 View Gestures (Zoom): Pages with 'background-attachment: fixed' don't behave correctly when zoomed
1800 https://bugs.webkit.org/show_bug.cgi?id=132225
1801 <rdar://problem/15729975>
1803 Reviewed by Darin Adler.
1805 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
1806 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1807 (WebKit::TiledCoreAnimationDrawingArea::layerForTransientZoom):
1808 (WebKit::TiledCoreAnimationDrawingArea::shadowLayerForTransientZoom):
1809 (WebKit::TiledCoreAnimationDrawingArea::adjustTransientZoom):
1810 (WebKit::TiledCoreAnimationDrawingArea::commitTransientZoom):
1811 (WebKit::TiledCoreAnimationDrawingArea::applyTransientZoomToPage):
1812 Factor out code to choose which layer (and shadow layer) to apply the transient zoom to.
1813 If we have a contentsContainmentLayer (because we have composited background-attachment: fixed),
1814 it applies page scale, so we should apply the transient zoom to that layer
1815 instead of the RenderView's main GraphicsLayer.
1817 2014-04-27 Pratik Solanki <psolanki@apple.com>
1819 Unreviewed. iOS build fix.
1821 * UIProcess/ios/SmartMagnificationController.h:
1823 2014-04-27 Zan Dobersek <zdobersek@igalia.com>
1825 Move cross-port WebKit2 code to std::unique_ptr
1826 https://bugs.webkit.org/show_bug.cgi?id=129670
1828 Reviewed by Darin Adler.
1830 Replace uses of OwnPtr, PassOwnPtr in cross-port WebKit2 code with std::unique_ptr.
1832 * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
1833 (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createIndex):
1834 * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
1835 * NetworkProcess/NetworkProcess.h:
1836 (WebKit::NetworkProcess::addSupplement):
1837 * NetworkProcess/SynchronousNetworkLoaderClient.cpp:
1838 (WebKit::SynchronousNetworkLoaderClient::didReceiveBuffer):
1839 * NetworkProcess/SynchronousNetworkLoaderClient.h:
1840 * Platform/IPC/Connection.cpp:
1841 (IPC::Connection::dispatchWorkQueueMessageReceiverMessage):
1842 * Platform/IPC/Connection.h:
1843 * Platform/IPC/MessageReceiver.h:
1844 * Platform/Module.h:
1845 * Platform/WorkQueue.h:
1846 * Platform/efl/ModuleEfl.cpp:
1847 (WebKit::Module::load):
1848 * Platform/mac/LayerHostingContext.mm:
1850 * Shared/Network/CustomProtocols/CustomProtocolManager.h:
1851 * Shared/Plugins/NPRemoteObjectMap.cpp:
1852 * Shared/ShareableBitmap.h:
1853 * UIProcess/DrawingAreaProxyImpl.h:
1854 * UIProcess/InspectorServer/WebSocketServer.cpp:
1855 (WebKit::WebSocketServer::didAcceptConnection):
1856 (WebKit::WebSocketServer::didCloseWebSocketServerConnection):
1857 * UIProcess/InspectorServer/WebSocketServer.h:
1858 * UIProcess/InspectorServer/soup/WebSocketServerSoup.cpp:
1859 (WebKit::connectionCallback):
1860 * UIProcess/Network/NetworkProcessProxy.cpp:
1861 (WebKit::NetworkProcessProxy::createDownloadProxy):
1862 * UIProcess/Network/NetworkProcessProxy.h:
1863 * UIProcess/Notifications/WebNotificationManagerProxy.h:
1864 * UIProcess/Plugins/WebPluginSiteDataManager.cpp:
1865 (WebKit::WebPluginSiteDataManager::getSitesWithData):
1866 (WebKit::WebPluginSiteDataManager::clearSiteData):
1867 (WebKit::WebPluginSiteDataManager::didGetSitesWithDataForAllPlugins):
1868 (WebKit::WebPluginSiteDataManager::didClearSiteDataForAllPlugins):
1869 * UIProcess/Plugins/WebPluginSiteDataManager.h:
1870 * UIProcess/Storage/StorageManager.cpp:
1871 (WebKit::callCallbackFunction):
1872 (WebKit::StorageManager::getOriginsInternal):
1873 * UIProcess/WebPageProxy.cpp:
1874 (WebKit::ExceededDatabaseQuotaRecords::areBeingProcessed):
1875 (WebKit::ExceededDatabaseQuotaRecords::createRecord):
1876 (WebKit::ExceededDatabaseQuotaRecords::add):
1877 (WebKit::ExceededDatabaseQuotaRecords::next):
1878 (WebKit::WebPageProxy::handleMouseEvent):
1879 (WebKit::WebPageProxy::handleWheelEvent):
1880 (WebKit::WebPageProxy::processNextQueuedWheelEvent):
1881 (WebKit::WebPageProxy::internalShowContextMenu):
1882 * UIProcess/WebPageProxy.h:
1883 * UIProcess/WebProcessProxy.cpp:
1884 (WebKit::WebProcessProxy::createDownloadProxy):
1885 * UIProcess/WebProcessProxy.h:
1886 * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1887 (WebKit::PluginDestructionProtector::PluginDestructionProtector):
1888 * WebProcess/Plugins/Netscape/NetscapePluginStream.cpp:
1889 (WebKit::NetscapePluginStream::deliverData):
1890 * WebProcess/Plugins/Netscape/NetscapePluginStream.h:
1891 * WebProcess/Plugins/PluginProcessConnectionManager.h:
1892 * WebProcess/Plugins/PluginProxy.cpp:
1893 (WebKit::PluginProxy::initialize):
1894 (WebKit::PluginProxy::didCreatePluginInternal):
1895 (WebKit::PluginProxy::didFailToCreatePluginInternal):
1896 * WebProcess/Plugins/PluginProxy.h:
1897 * WebProcess/Plugins/PluginView.cpp:
1898 (WebKit::PluginView::createWebEvent):
1899 (WebKit::PluginView::handleEvent):
1900 * WebProcess/Plugins/PluginView.h:
1901 * WebProcess/WebCoreSupport/WebPopupMenu.h:
1902 * WebProcess/WebPage/EventDispatcher.cpp:
1903 (WebKit::EventDispatcher::EventDispatcher):
1904 * WebProcess/WebPage/EventDispatcher.h:
1905 * WebProcess/WebPage/WebPage.cpp:
1906 (WebKit::WebPage::WebPage):
1907 (WebKit::WebPage::beginPrinting):
1908 * WebProcess/WebPage/WebPage.h:
1909 * WebProcess/WebProcess.h:
1910 (WebKit::WebProcess::addSupplement):
1912 2014-04-27 Antti Koivisto <antti@apple.com>
1914 Coalesce responses on network process side
1915 https://bugs.webkit.org/show_bug.cgi?id=132229
1917 Reviewed by Andreas Kling.
1919 To reduce IPC we should coalesce response data in the network process and send it over with single IPC call.
1921 * NetworkProcess/AsynchronousNetworkLoaderClient.cpp:
1922 (WebKit::AsynchronousNetworkLoaderClient::AsynchronousNetworkLoaderClient):
1923 (WebKit::AsynchronousNetworkLoaderClient::didReceiveResponse):
1924 (WebKit::AsynchronousNetworkLoaderClient::didReceiveBuffer):
1925 (WebKit::AsynchronousNetworkLoaderClient::didFinishLoading):
1926 (WebKit::AsynchronousNetworkLoaderClient::didFail):
1927 (WebKit::AsynchronousNetworkLoaderClient::dispatchPartialCoalescedResponse):
1928 (WebKit::AsynchronousNetworkLoaderClient::clearCoalescedResponse):
1929 (WebKit::AsynchronousNetworkLoaderClient::responseCoalesceTimerFired):
1931 Coalesce the response. Completed response is sent on didFinishLoading. If the coalesce timer fires
1932 before that the data accumulated so far is dispatched.
1934 * NetworkProcess/AsynchronousNetworkLoaderClient.h:
1935 * NetworkProcess/NetworkResourceLoader.h:
1936 * WebProcess/Network/WebResourceLoader.cpp:
1937 (WebKit::WebResourceLoader::didReceiveCompleteResponse):
1938 * WebProcess/Network/WebResourceLoader.h:
1939 * WebProcess/Network/WebResourceLoader.messages.in:
1941 Add a new message type that covers didReceiveResponse, didReceiveBuffer and didFinishLoading in a single message.
1943 2014-04-26 Tim Horton <timothy_horton@apple.com>
1945 REGRESSION (r167775): Safari crashes in ViewSnapshotStore::pruneSnapshots after loading 20 pages
1946 https://bugs.webkit.org/show_bug.cgi?id=132204
1947 <rdar://problem/16735622>
1949 Reviewed by Dan Bernstein and Sam Weinig.
1951 * UIProcess/mac/ViewSnapshotStore.mm:
1952 (WebKit::ViewSnapshotStore::pruneSnapshots):
1953 (WebKit::ViewSnapshotStore::recordSnapshot):
1954 Fix a bug where the count of snapshots with live images was too high
1955 because we were failing to decrement it when replacing a snapshot of
1956 an existing item with a fresh one.
1958 2014-04-26 Dan Bernstein <mitz@apple.com>
1960 [Cocoa] Rename a bundle form delegate method
1961 https://bugs.webkit.org/show_bug.cgi?id=132221
1963 Reviewed by Adele Peterson.
1965 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h: Renamed.
1966 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
1967 (-[WKWebProcessPlugInBrowserContextController _setFormDelegate:]): Check for the method
1968 under the old (“new”) name and under the new name.
1970 2014-04-25 Dan Bernstein <mitz@apple.com>
1972 [Cocoa] Synthesized getter for WKNavigationAction's _userInitiated property has the wrong name
1973 https://bugs.webkit.org/show_bug.cgi?id=132219
1975 Reviewed by Sam Weinig.
1977 * UIProcess/API/Cocoa/WKNavigationActionInternal.h:
1979 2014-04-25 Simon Fraser <simon.fraser@apple.com>
1981 [iOS] getAssistedNodeInformation crashes getting the bounding box if it doesn't have a renderer
1982 https://bugs.webkit.org/show_bug.cgi?id=132217
1983 <rdar://problem/16671662>
1985 Reviewed by Dean Jackson.
1987 * WebProcess/WebPage/ios/WebPageIOS.mm:
1988 (WebKit::WebPage::getAssistedNodeInformation): Check that m_assistedNode has
1989 a renderer before asking for its bounding box.
1991 2014-04-25 Benjamin Poulain <bpoulain@apple.com>
1993 [iOS][WK2] Add an intermediary view to do the target transform and adjustment transform
1994 https://bugs.webkit.org/show_bug.cgi?id=132175
1996 Reviewed by Enrica Casucci.
1998 Some utility views of WKContentView account for the transforms between the content view
1999 and the utility view.
2001 Since the dynamic resize relies on setting subLayerTransforms, it is getting in the way.
2003 This patch adds a layer in between for the animation. That way the content view remains
2006 * UIProcess/API/Cocoa/WKWebView.mm:
2007 (-[WKWebView _didCommitLayerTree:WebKit::]):
2008 (-[WKWebView _dynamicViewportUpdateChangedTargetToScale:position:]):
2009 (-[WKWebView _beginAnimatedResizeWithUpdates:]):
2010 (-[WKWebView _endAnimatedResize]):
2012 2014-04-25 Enrica Casucci <enrica@apple.com>
2014 REGRESSION (iOS WebKit2): Selection is not being repainted during live resize.
2015 https://bugs.webkit.org/show_bug.cgi?id=132216
2016 <rdar://problem/16628819>
2018 Reviewed by Benjamin Poulain.
2020 Since the selection is drawn in the UIProcess on iOS,
2021 we need to update the selection rects and force a repaint
2022 during a live resize.
2024 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2025 (WebKit::WebFrameLoaderClient::dispatchDidLayout):
2026 * WebProcess/WebPage/WebPage.h:
2027 * WebProcess/WebPage/ios/WebPageIOS.mm:
2028 (WebKit::WebPage::updateSelectionAppearance):
2030 2014-04-25 Brady Eidson <beidson@apple.com>
2032 Add a selection overlay.
2033 <rdar://problem/16727797> and https://bugs.webkit.org/show_bug.cgi?id=132200
2035 Reviewed by David Hyatt.
2037 * WebKit2.xcodeproj/project.pbxproj:
2039 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2040 (WebKit::WebEditorClient::selectionRectsDidChange): Pass the new selection rects on
2041 to the selection overlay controller.
2042 * WebProcess/WebCoreSupport/WebEditorClient.h:
2044 * WebProcess/WebPage/SelectionOverlayController.cpp: Added.
2045 (WebKit::SelectionOverlayController::SelectionOverlayController):
2046 (WebKit::SelectionOverlayController::createOverlayIfNeeded):
2047 (WebKit::SelectionOverlayController::destroyOverlay):
2048 (WebKit::SelectionOverlayController::pageOverlayDestroyed):
2049 (WebKit::SelectionOverlayController::willMoveToWebPage):
2050 (WebKit::SelectionOverlayController::didMoveToWebPage):
2051 (WebKit::SelectionOverlayController::selectionRectsDidChange):
2052 (WebKit::SelectionOverlayController::drawRect):
2053 (WebKit::SelectionOverlayController::mouseEvent):
2054 * WebProcess/WebPage/SelectionOverlayController.h: Added.
2055 (WebKit::SelectionOverlayController::create):
2056 * WebProcess/WebPage/mac/SelectionOverlayControllerMac.mm: Added.
2057 (WebKit::SelectionOverlayController::drawRect):
2058 (WebKit::SelectionOverlayController::mouseEvent):
2059 (WebKit::SelectionOverlayController::handleClick):
2060 (WebKit::SelectionOverlayController::clearHighlight):
2062 * WebProcess/WebPage/WebPage.cpp:
2063 (WebKit::WebPage::selectionOverlayController):
2064 * WebProcess/WebPage/WebPage.h:
2066 2014-04-25 Enrica Casucci <enrica@apple.com>
2068 Remove duplicate member variable in WKAutocorrectionRects and WKAutocorrectionContext.
2069 https://bugs.webkit.org/show_bug.cgi?id=132206
2071 Reviewed by Benjamin Poulain.
2073 * UIProcess/ios/WKContentViewInteraction.mm:
2075 2014-04-25 Dean Jackson <dino@apple.com>
2077 Allow a platform-specific size enumeration to be passed into popup-menu display
2078 https://bugs.webkit.org/show_bug.cgi?id=132195
2080 Reviewed by Brent Fulgham. With some in-person review comments from Sam Weinig.
2082 Platforms like OS X use a set of predefined sizes for built-in controls
2083 used for <select>: normal, small and mini. Expose that information to
2084 the PopupMenuClient via the PopupMenuStyle, allowing it to be passed
2085 into the platform code in WebKitSystemInterface.
2087 * Shared/PlatformPopupMenuData.cpp: Encode and decode the PopupMenuSize enum.
2088 (WebKit::PlatformPopupMenuData::encode):
2089 (WebKit::PlatformPopupMenuData::decode):
2090 * Shared/PlatformPopupMenuData.h: Add PopupMenuSize member variable.
2091 * UIProcess/mac/WebPopupMenuProxyMac.mm:
2092 (WebKit::WebPopupMenuProxyMac::showPopupMenu): Convert the PopupMenuSize
2093 into a WKControlSize, and pass that into WKPopupMenu.
2094 * WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm:
2095 (WebKit::WebPopupMenu::setUpPlatformData): Add the PopupMenuSize to
2096 the PlatformPopupMenuData.
2098 2014-04-25 Tim Horton <timothy_horton@apple.com>
2100 REGRESSION (r167775): Safari crashes in ViewSnapshotStore::pruneSnapshots after loading 20 pages
2101 https://bugs.webkit.org/show_bug.cgi?id=132204
2102 <rdar://problem/16729123>
2104 Reviewed by Anders Carlsson.
2106 * UIProcess/mac/ViewSnapshotStore.h:
2107 * UIProcess/mac/ViewSnapshotStore.mm:
2108 (WebKit::ViewSnapshotStore::ViewSnapshotStore):
2109 (WebKit::ViewSnapshotStore::pruneSnapshots):
2110 (WebKit::ViewSnapshotStore::recordSnapshot):
2111 Keep track of the number of snapshots that actually have live images; the
2112 size of the snapshot map no longer represents that.
2113 Also, fix the crash by using the UUID from the current item instead of from
2114 the (potentially null) most distant item; r167775 accidentally typo'd this.
2116 2014-04-25 Carlos Garcia Campos <cgarcia@igalia.com>
2118 [GTK] Plugin process crashes with GTK2 windowed plugins
2119 https://bugs.webkit.org/show_bug.cgi?id=132127
2121 Reviewed by Martin Robinson.
2123 It happens sometimes because the socket is used before the plug
2124 has been added. A runtime critical warnings is shown and it
2125 sometimes ends up crashing.
2127 * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
2128 (WebKit::NetscapePlugin::platformPostInitializeWindowed): Do not
2129 show the plug widget until the socket is connected.
2131 2014-04-24 Andreas Kling <akling@apple.com>
2133 [iOS WebKit2] Enable optimization to mmap downloaded resources once they become file-backed.
2134 <https://webkit.org/b/132171>
2135 <rdar://problem/16720733>
2137 Implement a CFNetwork-based version of NetworkResourceLoader::willCacheResponseAsync()
2138 and activate the DiskCacheMonitor code path. This means that once resources go into
2139 file system cache, we get notified and mmap them from disk, saving heaps of memory.
2141 Reviewed by Antti Koivisto.
2143 * NetworkProcess/NetworkResourceLoader.h:
2144 * NetworkProcess/mac/DiskCacheMonitor.mm:
2145 * NetworkProcess/mac/NetworkResourceLoaderMac.mm:
2146 (WebKit::NetworkResourceLoader::willCacheResponseAsync):
2148 2014-04-24 Andreas Kling <akling@apple.com>
2150 [iOS WebKit2] RemoteLayerTreeDrawingArea should force CA to garbage collect surfaces.
2151 <https://webkit.org/b/132160>
2152 <rdar://problem/16110687>
2154 Do an empty CATransaction at the end of RemoteLayerTreeDrawingArea::flushLayers()
2155 to get CA to garbage collect its IOSurfaces. This helps clean up unused surfaces
2156 that we'd otherwise end up hanging on to for a long time.
2158 Reviewed by Tim Horton.
2160 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
2161 (WebKit::RemoteLayerTreeDrawingArea::didUpdate):
2163 2014-04-24 Commit Queue <commit-queue@webkit.org>
2165 Unreviewed, rolling out r167700.
2166 https://bugs.webkit.org/show_bug.cgi?id=132142
2168 Incorrectly reverted the change in r167547 for
2169 webkit.org/b/131898 (Requested by rniwa on #webkit).
2173 "Cursor doesn't change back to pointer when leaving the Safari
2175 https://bugs.webkit.org/show_bug.cgi?id=132038
2176 http://trac.webkit.org/changeset/167700
2178 2014-04-24 Brady Eidson <beidson@apple.com>
2180 Rename "IMAGE_CONTROLS" feature to "SERVICE_CONTROLS"
2181 https://bugs.webkit.org/show_bug.cgi?id=132155
2183 Reviewed by Tim Horton.
2185 * Configurations/FeatureDefines.xcconfig:
2186 * Shared/ContextMenuContextData.cpp:
2187 (WebKit::ContextMenuContextData::ContextMenuContextData):
2188 (WebKit::ContextMenuContextData::operator=):
2189 (WebKit::ContextMenuContextData::encode):
2190 (WebKit::ContextMenuContextData::decode):
2191 * Shared/ContextMenuContextData.h:
2192 * UIProcess/WebPageProxy.cpp:
2193 (WebKit::WebPageProxy::internalShowContextMenu):
2194 * UIProcess/WebPageProxy.h:
2195 * UIProcess/mac/WebContextMenuProxyMac.h:
2196 * UIProcess/mac/WebContextMenuProxyMac.mm:
2197 (WebKit::WebContextMenuProxyMac::contextMenuItemSelected):
2198 (WebKit::WebContextMenuProxyMac::populate):
2199 (WebKit::WebContextMenuProxyMac::showContextMenu):
2200 * WebProcess/InjectedBundle/InjectedBundle.cpp:
2201 (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
2202 * WebProcess/WebPage/WebContextMenu.cpp:
2203 * WebProcess/WebPage/WebContextMenu.h:
2204 * WebProcess/WebPage/WebPage.cpp:
2205 (WebKit::WebPage::updatePreferences):
2206 * WebProcess/WebPage/WebPage.h:
2207 * WebProcess/WebPage/WebPage.messages.in:
2209 2014-04-24 Joseph Pecoraro <pecoraro@apple.com>
2211 [iOS] Add some missing overrides and remove unnecessary virtuals
2212 https://bugs.webkit.org/show_bug.cgi?id=132153
2214 Reviewed by Darin Adler.
2216 * UIProcess/ios/PageClientImplIOS.h:
2217 * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
2219 2014-04-24 Tim Horton <timothy_horton@apple.com>
2221 WebKit2 View Gestures: Use a single struct for the snapshot, and pass it around
2222 https://bugs.webkit.org/show_bug.cgi?id=132114
2224 Reviewed by Simon Fraser.
2226 Have only a single map in ViewSnapshotStore, from back-forward item
2227 to ViewSnapshotStore::Snapshot, and return the Snapshot struct when looking
2228 up snapshots (via getSnapshot()), so that future patches can persist additional
2229 information along with the snapshot.
2231 * UIProcess/ios/ViewGestureControllerIOS.mm:
2232 (WebKit::ViewGestureController::beginSwipeGesture):
2233 (WebKit::ViewGestureController::endSwipeGesture):
2234 * UIProcess/mac/ViewGestureController.h:
2235 * UIProcess/mac/ViewGestureControllerMac.mm:
2236 (WebKit::ViewGestureController::retrieveSnapshotForItem):
2237 (WebKit::ViewGestureController::beginSwipeGesture):
2238 (WebKit::ViewGestureController::endSwipeGesture):
2239 Adopt getSnapshot() instead of snapshotAndRenderTreeSize().
2240 Move retrieveSnapshotForItem out into a separate function (for future use).
2242 * UIProcess/mac/ViewSnapshotStore.h:
2243 (WebKit::ViewSnapshotStore::disableSnapshotting):
2244 (WebKit::ViewSnapshotStore::enableSnapshotting):
2245 * UIProcess/mac/ViewSnapshotStore.mm:
2246 (WebKit::ViewSnapshotStore::pruneSnapshots):
2247 (WebKit::ViewSnapshotStore::recordSnapshot):
2248 (WebKit::ViewSnapshotStore::getSnapshot):
2249 (WebKit::ViewSnapshotStore::snapshotAndRenderTreeSize): Deleted.
2250 Make Snapshot struct public.
2251 Get rid of the separate map of back-forward items to render tree sizes.
2252 When evicting, instead of removing the entry, clear out its snapshot image;
2253 this way, we can keep other snapshot metadata around.
2255 2014-04-24 Enrica Casucci <enrica@apple.com>
2257 [iOS WebKit2] Should properly handle focus redirect (keyboard state changes when focus changes).
2258 https://bugs.webkit.org/show_bug.cgi?id=132136
2259 <rdar://problem/16238336>
2261 Reviewed by Benjamin Poulain.
2263 Focusing a field from JavaScript should not make the keyboard or the select picker
2264 appear unless the user has already started interacting with one of the fields in the page.
2265 Adding a parameter to StartAssistingNode to indicate whether the focus change is a result
2268 * UIProcess/PageClient.h:
2269 * UIProcess/WebPageProxy.h:
2270 * UIProcess/WebPageProxy.messages.in:
2271 * UIProcess/ios/PageClientImplIOS.h:
2272 * UIProcess/ios/PageClientImplIOS.mm:
2273 (WebKit::PageClientImpl::startAssistingNode):
2274 * UIProcess/ios/WKContentViewInteraction.h:
2275 * UIProcess/ios/WKContentViewInteraction.mm:
2276 (-[WKContentView _startAssistingNode:userIsInteracting:userObject:]):
2277 * UIProcess/ios/WebPageProxyIOS.mm:
2278 (WebKit::WebPageProxy::startAssistingNode):
2279 * WebProcess/WebPage/WebPage.cpp:
2280 (WebKit::WebPage::WebPage):
2281 (WebKit::WebPage::dispatchTouchEvent):
2282 * WebProcess/WebPage/WebPage.h:
2283 * WebProcess/WebPage/ios/WebPageIOS.mm:
2284 (WebKit::WebPage::handleTap):
2285 (WebKit::WebPage::elementDidFocus):
2287 2014-04-24 Myles C. Maxfield <mmaxfield@apple.com>
2289 FontCache::fontCache() never returns nullptr so it can be made to return a reference instead
2290 https://bugs.webkit.org/show_bug.cgi?id=132110
2292 Reviewed by Tim Horton.
2294 Updates callers to use '.' instead of '->'.
2296 No new tests are necessary because there should be no behavior change.
2298 * WebProcess/WebProcess.cpp:
2299 (WebKit::WebProcess::terminate):
2300 (WebKit::WebProcess::didClose):
2301 (WebKit::WebProcess::getWebCoreStatistics):
2303 2014-04-24 Eric Carlson <eric.carlson@apple.com>
2305 [iOS] Manage AudioSession category according to media type
2306 https://bugs.webkit.org/show_bug.cgi?id=132096
2308 Reviewed by Jer Noble.
2310 * WebProcess/WebPage/WebPage.cpp:
2311 (WebKit::WebPage::WebPage): Tell WebCore to manage the AudioSession.
2313 2014-04-24 Tim Horton <timothy_horton@apple.com>
2315 [wk2] Provide SPI allowing clients to hand events directly to swipe code, bypassing scrolling
2316 https://bugs.webkit.org/show_bug.cgi?id=132092
2317 <rdar://problem/15948244>
2319 Reviewed by Darin Adler.
2321 * UIProcess/API/Cocoa/WKViewPrivate.h:
2322 * UIProcess/API/mac/WKView.mm:
2323 (-[WKView _tryToSwipeWithEvent:ignoringPinnedState:]):
2324 Added. Hand the event directly to ViewGestureController, optionally
2325 ignoring whether or not the WKView is scrollable (always pretending that it is not).
2327 * UIProcess/mac/ViewGestureController.h:
2328 (WebKit::ViewGestureController::shouldIgnorePinnedState):
2329 (WebKit::ViewGestureController::setShouldIgnorePinnedState):
2330 * UIProcess/mac/ViewGestureControllerMac.mm:
2331 (WebKit::ViewGestureController::ViewGestureController):
2332 (WebKit::ViewGestureController::scrollEventCanBecomeSwipe):
2333 (WebKit::ViewGestureController::handleScrollWheelEvent):
2334 (WebKit::ViewGestureController::wheelEventWasNotHandledByWebCore):
2335 (WebKit::scrollEventCanBecomeSwipe):
2336 If we're ignoring the view's pinned state, pretend that we're always pinned,
2337 and don't worry about sending events to WebCore.
2339 2014-04-24 Carlos Garcia Campos <cgarcia@igalia.com>
2341 [GTK] wmode='transparent' for flash plugin doesn't work
2342 https://bugs.webkit.org/show_bug.cgi?id=120055
2344 Reviewed by Gustavo Noronha Silva.
2346 Force opaque window mode for flash plugin when wmode='transparent',
2347 since X11 backend doesn't support transparency. We should add
2348 proper transparency support because forcing opaque window mode
2349 doesn't really work. Handle this as a plugin quirk instead of
2350 adding X11 specific code to WebFrameLoaderClient::createPlugin().
2352 * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
2353 (WebKit::NetscapePluginModule::determineQuirks): Add
2354 ForceFlashWindowlessMode quirk for flash in case of EFL platform
2355 because EFL port doesn't support windowed plugins.
2356 * Shared/Plugins/PluginQuirks.h: Add ForceFlashWindowlessMode X11
2358 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2359 (WebKit::NetscapePlugin::initialize): Modify or add wmode
2360 parameter for flash plugin, to force opaque window mode when
2361 transparent mode is specified or when ForceFlashWindowlessMode
2363 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2364 (WebKit::WebFrameLoaderClient::createPlugin): Remove X11 specific code.
2366 2014-04-23 Simon Fraser <simon.fraser@apple.com>
2368 [iOS WK2] Missing content inside long overflow-scrolling:touch
2369 https://bugs.webkit.org/show_bug.cgi?id=132105
2371 Reviewed by Tim Horton.
2373 PlatformCALayerRemote needs to track bounds origin as well as size,
2374 since iOS uses bounds origin for overflow scrolling.
2376 * Shared/mac/RemoteLayerTreePropertyApplier.mm:
2377 (WebKit::applyPropertiesToLayer):
2378 * Shared/mac/RemoteLayerTreeTransaction.h:
2379 * Shared/mac/RemoteLayerTreeTransaction.mm:
2380 (WebKit::RemoteLayerTreeTransaction::LayerProperties::LayerProperties):
2381 (WebKit::RemoteLayerTreeTransaction::LayerProperties::encode):
2382 (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
2383 (WebKit::dumpChangedLayers):
2384 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
2385 (WebKit::PlatformCALayerRemote::updateBackingStore):
2386 (WebKit::PlatformCALayerRemote::bounds):
2387 (WebKit::PlatformCALayerRemote::setBounds):
2389 2014-04-23 Andreas Kling <akling@apple.com>
2391 Remove unused WKPageSetMemoryCacheClientCallsEnabled API.
2392 <https://webkit.org/b/132098>
2394 This API was added to WK2 back in 2011 but never actually used.
2396 Reviewed by Anders Carlsson.
2398 * Shared/WebPageCreationParameters.cpp:
2399 (WebKit::WebPageCreationParameters::encode):
2400 (WebKit::WebPageCreationParameters::decode):
2401 * Shared/WebPageCreationParameters.h:
2402 * UIProcess/API/C/WKPage.cpp:
2403 (WKPageSetMemoryCacheClientCallsEnabled): Deleted.
2404 * UIProcess/API/C/WKPage.h:
2405 * UIProcess/WebPageProxy.cpp:
2406 (WebKit::WebPageProxy::WebPageProxy):
2407 (WebKit::WebPageProxy::creationParameters):
2408 (WebKit::WebPageProxy::setMemoryCacheClientCallsEnabled): Deleted.
2409 * UIProcess/WebPageProxy.h:
2410 * WebProcess/WebPage/WebPage.cpp:
2411 (WebKit::WebPage::WebPage):
2412 (WebKit::WebPage::setMemoryCacheMessagesEnabled): Deleted.
2413 * WebProcess/WebPage/WebPage.h:
2414 * WebProcess/WebPage/WebPage.messages.in:
2416 2014-04-23 Simon Fraser <simon.fraser@apple.com>
2418 [iOS WK2] Make -webkit-overflow-scrolling:touch work
2419 https://bugs.webkit.org/show_bug.cgi?id=132097
2421 Reviewed by Tim Horton.
2423 Scrolling of UIScrollViews in content (for -webkit-overflow-scrolling:touch)
2424 depends on them getting hit-tested correctly. UIKit hit testing assumes
2425 that subviews are enclosed by their ancestors, but this is not true of
2426 web content. In addition, we had a root layer that was zero sized.
2428 Fix by overriding hitTest:withEvent: on our content WKViews to hit
2429 test subviews even if they are not enclosed.
2431 * UIProcess/ios/RemoteLayerTreeHostIOS.mm:
2432 (-[UIView _recursiveFindDescendantViewAtPoint:withEvent:]):
2433 (-[UIView _findDescendantViewAtPoint:withEvent:]):
2434 (-[WKCompositingView hitTest:withEvent:]):
2435 (-[WKTransformView hitTest:withEvent:]):
2436 (-[WKRemoteView hitTest:withEvent:]):
2437 (WebKit::RemoteLayerTreeHost::createLayer):
2438 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
2439 (WebKit::RemoteLayerTreeDrawingArea::updatePreferences):
2440 Update debug borders on the root layer.
2441 (WebKit::RemoteLayerTreeDrawingArea::mainFrameContentSizeChanged):
2442 Size the root layer to the contents size. This isn't strictly necessary
2443 given the hit testing overrides, but seems sensible to do anyway.
2445 2014-04-23 Simon Fraser <simon.fraser@apple.com>
2447 Nonopaque layers double-paint with UI-side compositing
2448 https://bugs.webkit.org/show_bug.cgi?id=132101
2450 Reviewed by Tim Horton.
2452 The non-IOSurface code path was failing to clear the backing store
2455 * Shared/mac/RemoteLayerBackingStore.mm:
2456 (WebKit::RemoteLayerBackingStore::display):
2457 (WebKit::RemoteLayerBackingStore::drawInContext):
2459 2014-04-23 Benjamin Poulain <bpoulain@apple.com>
2461 [iOS][WK2] Image and text documents sometime gets the webpage viewport configuration
2462 https://bugs.webkit.org/show_bug.cgi?id=132099
2464 Reviewed by Tim Horton.
2466 When didReceiveMobileDocType(), if the doctype was not XHTML mobile, we were setting
2467 the viewport configuration to webpageParameters(). This is obviously not correct for
2468 Image and Text documents.
2470 This patch moves the code deciding the default configuration out of WebPage::didCommitLoad()
2471 and use it from WebPage::didCommitLoad() and WebPage::didReceiveMobileDocType().
2473 * WebProcess/WebPage/WebPage.cpp:
2474 (WebKit::WebPage::didCommitLoad):
2475 * WebProcess/WebPage/WebPage.h:
2476 * WebProcess/WebPage/ios/WebPageIOS.mm:
2477 (WebKit::WebPage::didReceiveMobileDocType):
2478 (WebKit::WebPage::resetViewportDefaultConfiguration):
2480 2014-04-23 Benjamin Poulain <bpoulain@apple.com>
2482 [iOS][WK2] Fix a few mistakes affecting the initial layout and the initial unobscured rect
2483 https://bugs.webkit.org/show_bug.cgi?id=132093
2484 <rdar://problem/16703237>
2486 Reviewed by Tim Horton.
2488 The user of WKWebView can setup a size on device pixels, which can add half a point to the minimum
2489 layout size. By rounding this up before applying the page scale, we ended up with rounding errors
2490 on the layout size and the transitory unobscured content rect.
2492 This patch fixes changes the minimal layout size to float point values to reduce the rounding problems.
2494 * UIProcess/API/Cocoa/WKWebView.mm:
2495 (setViewportConfigurationMinimumLayoutSize):
2496 (-[WKWebView _setMinimumLayoutSizeOverrideForMinimalUI:]):
2497 (-[WKWebView _beginAnimatedResizeWithUpdates:]):
2498 * UIProcess/WebPageProxy.h:
2499 * UIProcess/ios/WebPageProxyIOS.mm:
2500 (WebKit::WebPageProxy::dynamicViewportSizeUpdate):
2501 (WebKit::WebPageProxy::setViewportConfigurationMinimumLayoutSize):
2502 (WebKit::WebPageProxy::setMinimumLayoutSizeForMinimalUI):
2504 * WebProcess/WebPage/WebPage.cpp:
2505 (WebKit::WebPage::didCommitLoad):
2506 Defaulting the content size to the minimum layout size only works if the initial-scale is 1.
2507 ViewportConfiguration knows exactly what to do before the first layout.
2509 * WebProcess/WebPage/WebPage.h:
2510 * WebProcess/WebPage/WebPage.messages.in:
2511 * WebProcess/WebPage/ios/WebPageIOS.mm:
2512 (WebKit::WebPage::setViewportConfigurationMinimumLayoutSize):
2513 (WebKit::WebPage::setMinimumLayoutSizeForMinimalUI):
2514 (WebKit::WebPage::dynamicViewportSizeUpdate):
2516 -setZoomedOutPageScaleFactor() was incorrectly using the initial scale. 99% of the time, initial scale
2517 and minimum scale are equal, but the page can specify something different with the viewport meta tag.
2518 -Use floating point for manipulating the minimum layout sizes, then round the value.
2519 -minimumLayoutSizeInDocumentCoordinate was scaled the wrong way around.
2521 (WebKit::WebPage::viewportConfigurationChanged):
2523 2014-04-23 Yongjun Zhang <yongjun_zhang@apple.com>
2525 Support encoding/decoding NSUInteger arguments in WKRemoteObjectCoder.
2526 https://bugs.webkit.org/show_bug.cgi?id=132040
2528 Add support for encoding/decoding NSUInteger arguments.
2530 Reviewed by Sam Weinig.
2532 * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
2534 (decodeInvocationArguments):
2536 2014-04-22 Ryosuke Niwa <rniwa@webkit.org>
2538 Cursor doesn't change back to pointer when leaving the Safari window
2539 https://bugs.webkit.org/show_bug.cgi?id=132038
2541 Reviewed by Alexey Proskuryakov.
2543 Since the cursor type is now updated asynchronously after r147739,
2544 [window windowNumber] != [NSWindow windowNumberAtPoint:[NSEvent mouseLocation] belowWindowWithWindowNumber:0]
2545 evalutes to false depending on how fast cursor is moving.
2547 Instead, check whether the NSWindow of the WebView is the key window or not since
2548 key window appears to control the cursor style in Cocoa as far as I've tested:
2549 https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/WinPanel/Concepts/ChangingMainKeyWindow.html
2551 * UIProcess/mac/PageClientImpl.mm:
2552 (WebKit::PageClientImpl::setCursor):
2554 2014-04-22 Yongjun Zhang <yongjun_zhang@apple.com>
2556 Add SPI to expose provisional URL from Frame.
2557 https://bugs.webkit.org/show_bug.cgi?id=132014
2559 Add methods to return the provisional URL from WKWebProcessPlugInFrame.
2561 Reviewed by Dan Bernstein.
2563 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm:
2564 (-[WKWebProcessPlugInFrame _provisionalURL]):
2565 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFramePrivate.h:
2567 2014-04-22 Benjamin Poulain <bpoulain@apple.com>
2569 [iOS][WK2] Split iOS touch event dispatch for the regular touch event dispatch
2570 https://bugs.webkit.org/show_bug.cgi?id=132033
2572 Reviewed by Simon Fraser.
2574 The generic touch event dispatching does not work well with iOS gesture recognizers.
2575 Some events are required to be synchronous, while other needs can be asynchronous and
2576 can even use event coalescing. We only need UI callback for the synchronous events.
2578 Previously, that was implemented by changing the property ShouldSendEventsSynchronously
2579 on WebPageProxy. That is causing issues when synchronous events are sent right after asynchronous
2580 events because the responses in WebPageProxy::didReceiveEvent() easily get out of order.
2582 This patch completely split the UIGestureRecognizerDispatching from the normal asynchronous event dispatching.
2584 Synchronous events are sent directly to the WebProcess and report the result to the PageClient right away.
2586 Asynchronous events are sent to the EventDispatcher where they are coalesced until the main thread is free
2589 There can be a race where a synchronous event comes before the asynchronous events are processed. In that case,
2590 the synchronous event handler starts by getting the events out of the EventDispatcher and dispatch them first.
2592 * Shared/NativeWebTouchEvent.h:
2593 (WebKit::NativeWebTouchEvent::uniqueId): Deleted.
2594 * Shared/ios/NativeWebTouchEventIOS.mm:
2595 (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
2596 * UIProcess/WebPageProxy.cpp:
2597 (WebKit::WebPageProxy::handleSynchronousTouchEvent):
2598 (WebKit::WebPageProxy::sendAsynchronousTouchEvent):
2599 (WebKit::WebPageProxy::didReceiveEvent):
2600 (WebKit::WebPageProxy::resetStateAfterProcessExited):
2601 * UIProcess/WebPageProxy.h:
2602 * UIProcess/ios/WKContentViewInteraction.h:
2603 * UIProcess/ios/WKContentViewInteraction.mm:
2604 (-[WKContentView _webTouchEventsRecognized:]):
2605 (-[WKContentView _webTouchEvent:WebKit::preventsNativeGestures:]):
2606 * WebProcess/WebPage/EventDispatcher.cpp:
2607 (WebKit::EventDispatcher::EventDispatcher):
2608 (WebKit::EventDispatcher::clearQueuedTouchEventsForPage):
2609 (WebKit::EventDispatcher::getQueuedTouchEventsForPage):
2610 (WebKit::EventDispatcher::touchEvent):
2611 (WebKit::EventDispatcher::dispatchTouchEvents):
2612 * WebProcess/WebPage/EventDispatcher.h:
2613 * WebProcess/WebPage/EventDispatcher.messages.in:
2614 * WebProcess/WebPage/WebPage.cpp:
2615 (WebKit::WebPage::dispatchTouchEvent):
2616 (WebKit::WebPage::touchEventSync):
2617 (WebKit::WebPage::touchEvent):
2618 (WebKit::WebPage::touchEventSyncForTesting):
2619 (WebKit::WebPage::didCommitLoad):
2620 * WebProcess/WebPage/WebPage.h:
2621 * WebProcess/WebPage/WebPage.messages.in:
2622 * WebProcess/WebPage/ios/WebPageIOS.mm:
2623 (WebKit::WebPage::dispatchAsynchronousTouchEventsQueue):
2625 2014-04-22 Chris Fleizach <cfleizach@apple.com>
2627 AX: iOS hit-testing does not work when page is zoomed
2628 https://bugs.webkit.org/show_bug.cgi?id=132013
2630 Reviewed by Simon Fraser.
2632 Implement accessibilityHitTest so that the point can be converted correctly.
2634 * WebProcess/WebPage/WKAccessibilityWebPageObjectIOS.mm:
2635 (-[WKAccessibilityWebPageObject accessibilityHitTest:]):
2637 2014-04-22 Commit Queue <commit-queue@webkit.org>
2639 Unreviewed, rolling out r167674.
2640 https://bugs.webkit.org/show_bug.cgi?id=132025
2642 Going a different way with this (Requested by bradee-oh on
2647 "Change Image Controls replacement to use selection and paste"
2648 https://bugs.webkit.org/show_bug.cgi?id=131992
2649 http://trac.webkit.org/changeset/167674
2651 2014-04-22 Joseph Pecoraro <pecoraro@apple.com>
2653 Remove unused local variable
2654 https://bugs.webkit.org/show_bug.cgi?id=132020
2656 Reviewed by Alexey Proskuryakov.
2658 * UIProcess/ios/forms/WKFormSelectPopover.mm:
2659 (-[WKSelectPopover initWithView:hasGroups:]):
2661 2014-04-22 Brady Eidson <beidson@apple.com>
2663 Change Image Controls replacement to use selection and paste
2664 <rdar://problem/16302722> and https://bugs.webkit.org/show_bug.cgi?id=131992
2666 Reviewed by Tim Horton.
2668 * UIProcess/mac/WebContextMenuProxyMac.mm:
2669 (-[WKSharingServicePickerDelegate sharingService:didShareItems:]): Write the
2670 replacement data to a special pasteboard, then replace the current selection from
2673 Remove all other code used to support the old replacement mechanism:
2674 * UIProcess/WebPageProxy.cpp:
2675 (WebKit::WebPageProxy::replaceControlledImage): Deleted.
2676 * UIProcess/WebPageProxy.h:
2677 * UIProcess/mac/WebContextMenuProxyMac.h:
2678 (WebKit::WebContextMenuProxyMac::page):
2679 (WebKit::WebContextMenuProxyMac::replaceControlledImage): Deleted.
2680 * WebProcess/WebPage/WebContextMenu.cpp:
2681 (WebKit::WebContextMenu::replaceControlledImage): Deleted.
2682 * WebProcess/WebPage/WebContextMenu.h:
2683 * WebProcess/WebPage/WebPage.cpp:
2684 (WebKit::WebPage::replaceControlledImage): Deleted.
2685 * WebProcess/WebPage/WebPage.h:
2686 * WebProcess/WebPage/WebPage.messages.in:
2688 2014-04-22 Eunmi Lee <eunmi15.lee@samsung.com>
2690 [EFL][WK2] Remove duplicated code to set size to the DrawingArea.
2691 https://bugs.webkit.org/show_bug.cgi?id=131972
2693 Reviewed by Andreas Kling.
2695 DrawingArea's size is set in the WebView.cpp when EwkView's size is
2696 changed, so we don't have to set again in the PageViewportController.
2698 * UIProcess/CoordinatedGraphics/PageViewportController.cpp:
2699 (WebKit::PageViewportController::didChangeViewportSize):
2701 2014-04-22 Tim Horton <timothy_horton@apple.com>
2703 WKThumbnailView doesn't quite work with topContentInset
2704 https://bugs.webkit.org/show_bug.cgi?id=131976
2705 <rdar://problem/16642127>
2707 Reviewed by Darin Adler.
2709 * UIProcess/API/Cocoa/_WKThumbnailView.mm:
2710 (-[_WKThumbnailView initWithFrame:fromWKView:]):
2711 _WKThumbnailView always needs a layer.
2712 We don't want to use snapshots by default, this was debugging accidentally landed in the last change.
2714 (-[_WKThumbnailView _requestSnapshotIfNeeded]):
2715 Don't request a new snapshot if the scale is the same as the existing one.
2716 Reduce the height of the snapshot by the topContentInset.
2717 Having the origin at (0, 0) is still correct, as the inset content is in negative Y space,
2718 and (0, 0) is the true origin of the content.
2720 (-[_WKThumbnailView setScale:]):
2721 When not snapshotting, we've decided that WKThumbnailView should apply the scale to the WKView layer tree,
2722 instead of depending on clients to do so.
2724 (-[_WKThumbnailView setUsesSnapshot:]):
2725 We *do* need to apply thumbnail scale in the web process even when snapshotting,
2726 because we use the live layer tree temporarily while waiting for the asynchronous
2727 snapshot to return. This was a misstep in the last thumbnail view patch.
2729 2014-04-22 Shivakumar JM <shiva.jm@samsung.com>
2731 [WebKit2] Cleanup the build from unused parameter in WebProcess Module
2732 https://bugs.webkit.org/show_bug.cgi?id=131970
2734 Reviewed by Darin Adler.
2736 Fix a build warning by removing the parameters in function paintLayerContents() to fix build warning.
2738 * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
2739 (WebKit::CoordinatedLayerTreeHost::paintLayerContents):
2741 2014-04-22 Carlos Garcia Campos <cgarcia@igalia.com>
2743 [GTK] Crash after getting web view context property with g_object_get
2744 https://bugs.webkit.org/show_bug.cgi?id=131983
2746 Reviewed by Philippe Normand.
2748 The problem is that the getter is using g_value_take_object() and
2749 the default context is destroyed when the caller releases its ref.
2751 * UIProcess/API/gtk/WebKitWebView.cpp:
2752 (webkitWebViewGetProperty): Use g_value_set_object() instead of
2753 g_value_take_object().
2755 2014-04-22 Ryuan Choi <ryuan.choi@samsung.com>
2757 [EFL][WK2] Remove unnecessary includes in files of Source/WebKit2/UIProcess/API/efl
2758 https://bugs.webkit.org/show_bug.cgi?id=131979
2760 Reviewed by Gyuyoung Kim.
2762 Removed unnecessary includes of header files.
2763 In addition, tried to use forward declarations.
2765 * UIProcess/API/efl/EwkView.cpp:
2766 * UIProcess/API/efl/EwkView.h:
2767 * UIProcess/API/efl/EwkViewCallbacks.h:
2768 * UIProcess/API/efl/GestureRecognizer.h:
2769 * UIProcess/API/efl/ewk_context_menu_item_private.h:
2770 * UIProcess/API/efl/ewk_context_menu_private.h:
2771 * UIProcess/API/efl/ewk_download_job.cpp:
2772 * UIProcess/API/efl/ewk_download_job_private.h:
2773 * UIProcess/API/efl/ewk_form_submission_request.cpp:
2774 * UIProcess/API/efl/ewk_form_submission_request_private.h:
2775 * UIProcess/API/efl/ewk_navigation_data.cpp:
2776 * UIProcess/API/efl/ewk_navigation_data_private.h:
2777 * UIProcess/API/efl/ewk_page_group_private.h:
2778 * UIProcess/API/efl/ewk_popup_menu_private.h:
2779 * UIProcess/API/efl/ewk_view.cpp:
2780 * UIProcess/API/efl/ewk_window_features_private.h:
2781 * UIProcess/efl/PageUIClientEfl.cpp:
2782 * UIProcess/efl/ViewClientEfl.cpp:
2784 2014-04-21 Tim Horton <timothy_horton@apple.com>
2786 [wk2] Don't send intrinsic content size updates with dirty layout
2787 https://bugs.webkit.org/show_bug.cgi?id=131964
2788 <rdar://problem/14292718>
2790 Reviewed by Simon Fraser.
2792 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2793 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2794 (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
2795 (WebKit::TiledCoreAnimationDrawingArea::mainFrameContentSizeChanged):
2796 (WebKit::TiledCoreAnimationDrawingArea::updateIntrinsicContentSizeIfNeeded):
2797 (WebKit::TiledCoreAnimationDrawingArea::flushLayers):
2798 (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
2799 (WebKit::TiledCoreAnimationDrawingArea::updateIntrinsicContentSizeTimerFired): Deleted.
2800 Instead of using a timer (which can fire while layout is dirty) to coalesce
2801 intrinsic content size changes, send them only from flushLayers, just after updating layout.
2802 This ensures that we never get intermediate intrinsic content sizes that won't be painted.
2804 2014-04-21 Tim Horton <timothy_horton@apple.com>
2806 Remove a unnecessary forward-declared class from TiledCoreAnimationDrawingArea.
2808 Rubber-stamped by Simon Fraser.
2810 * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2812 2014-04-21 Simon Fraser <simon.fraser@apple.com>
2814 Don't try to use a null connection()->xpcConnection()
2815 https://bugs.webkit.org/show_bug.cgi?id=131961
2817 Reviewed by Dan Bernstein.
2819 If running with -WebKit2UseXPCServiceForWebProcess NO, connection()->xpcConnection()
2820 is null and xpc_connection_get_pid() would crash, so null-check the xpcConnection.
2822 * UIProcess/Network/NetworkProcessProxy.cpp:
2823 (WebKit::NetworkProcessProxy::didFinishLaunching):
2825 2014-04-21 Dan Bernstein <mitz@apple.com>
2827 WebKit part of <rdar://problem/16631323> Page::setDefersLoading doesn’t do anything when using the Network process
2828 https://bugs.webkit.org/show_bug.cgi?id=131939
2830 Reviewed by David Kilzer.
2832 * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2833 (WebKit::NetworkConnectionToWebProcess::setDefersLoading): Added. Forwards the message to
2834 the NetworkResourceLoader.
2835 * NetworkProcess/NetworkConnectionToWebProcess.h:
2837 * NetworkProcess/NetworkConnectionToWebProcess.messages.in: Added SetDefersLoading message.
2839 * NetworkProcess/NetworkResourceLoader.cpp:
2840 (WebKit::NetworkResourceLoader::NetworkResourceLoader): Initialize new member variable
2841 m_defersLoading from the new field in the loader parameters.
2842 (WebKit::NetworkResourceLoader::start): Added. Like WebCore::ResourceLoader, if loading is
2843 deferred, keep the request in m_deferredRequest and bail out.
2844 (WebKit::NetworkResourceLoader::setDefersLoading): Added. Similar to
2845 WebCore::ResourceLoader::setDefersLoading.
2846 * NetworkProcess/NetworkResourceLoader.h:
2847 (WebKit::NetworkResourceLoader::defersLoading):
2849 * Shared/Network/NetworkResourceLoadParameters.cpp:
2850 (WebKit::NetworkResourceLoadParameters::NetworkResourceLoadParameters): Initialize new field
2851 defersLoading to false.
2852 (WebKit::NetworkResourceLoadParameters::encode): Encode new field.
2853 (WebKit::NetworkResourceLoadParameters::decode): Decode new field.
2854 * Shared/Network/NetworkResourceLoadParameters.h: Added defersLoading field.
2856 * WebProcess/Network/WebResourceLoadScheduler.cpp:
2857 (WebKit::WebResourceLoadScheduler::scheduleLoad): Populate defersLoading field in the load
2859 (WebKit::WebResourceLoadScheduler::setDefersLoading): Send a message to the Network process.
2860 * WebProcess/Network/WebResourceLoadScheduler.h:
2862 2014-04-21 Anders Carlsson <andersca@apple.com>
2864 Errors passed to delegate methods should have recovery attempters
2865 https://bugs.webkit.org/show_bug.cgi?id=131957
2866 <rdar://problem/16642539>
2868 Reviewed by Tim Horton.
2870 * UIProcess/API/Cocoa/_WKErrorRecoveryAttempting.h: Added.
2871 * UIProcess/API/Cocoa/_WKErrorRecoveryAttempting.mm: Added.
2872 * UIProcess/Cocoa/NavigationState.mm:
2873 (WebKit::createErrorWithRecoveryAttempter):
2874 (WebKit::NavigationState::LoaderClient::didFailProvisionalLoadWithErrorForFrame):
2875 (WebKit::NavigationState::LoaderClient::didFailLoadWithErrorForFrame):
2876 * UIProcess/Cocoa/WKReloadFrameErrorRecoveryAttempter.h: Added.
2877 * UIProcess/Cocoa/WKReloadFrameErrorRecoveryAttempter.mm: Added.
2878 (-[WKReloadFrameErrorRecoveryAttempter initWithWebView:frameHandle:urlString:]):
2879 (-[WKReloadFrameErrorRecoveryAttempter attemptRecovery]):
2880 * WebKit2.xcodeproj/project.pbxproj:
2882 2014-04-21 Eric Carlson <eric.carlson@apple.com>
2884 [Mac] implement WebKitDataCue
2885 https://bugs.webkit.org/show_bug.cgi?id=131799
2887 Reviewed by Dean Jackson.
2889 * Configurations/FeatureDefines.xcconfig: Define ENABLE_DATACUE_VALUE.
2891 2014-04-21 Beth Dakin <bdakin@apple.com>
2893 topContentInset does not play well with fullscreen elements
2894 https://bugs.webkit.org/show_bug.cgi?id=131955
2896 <rdar://problem/16651925>
2898 Reviewed by Sam Weinig.
2900 If you take an element (such as a <video>) fullscreen when you have a
2901 topContentInset set, there will be an inset-sized gap at the top of the fullscreen
2904 Save and restore the topContentInset whenever the scroll position is saved and
2906 * WebProcess/FullScreen/WebFullScreenManager.cpp:
2907 (WebKit::WebFullScreenManager::WebFullScreenManager):
2908 (WebKit::WebFullScreenManager::saveScrollPosition):
2909 (WebKit::WebFullScreenManager::restoreScrollPosition):
2910 * WebProcess/FullScreen/WebFullScreenManager.h:
2912 2014-04-21 Gavin Barraclough <baraclough@apple.com>
2914 Don't use ProcessAssertion on simulator
2915 https://bugs.webkit.org/show_bug.cgi?id=131950
2917 Rubber stamped by Enrica Casucci
2919 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2920 (WebKit::connectToService):
2921 * UIProcess/ios/ProcessAssertion.h:
2923 2014-04-21 Enrica Casucci <enrica@apple.com>
2925 [iOS WebKit2] support replacements for misspelled words.
2926 https://bugs.webkit.org/show_bug.cgi?id=131827
2927 <rdar://problem/16319657>
2929 Reviewed by Darin Adler.
2931 This is the second a final piece to support replacements.
2932 It adds some entrypoints used by the keyboard code to perform
2933 replacement when reaching the edge of a word using backspace.
2934 I've modified the behavior of replaceSelectedText to work both
2935 with caret or range selections.
2937 * Shared/EditorState.cpp:
2938 (WebKit::EditorState::encode):
2939 (WebKit::EditorState::decode):
2940 * Shared/EditorState.h:
2941 (WebKit::EditorState::EditorState):
2942 * UIProcess/ios/WKContentViewInteraction.mm:
2943 (-[WKContentView isReplaceAllowed]):
2944 (-[WKContentView _characterBeforeCaretSelection]):
2945 * WebProcess/WebPage/WebPage.cpp:
2946 (WebKit::WebPage::editorState):
2947 * WebProcess/WebPage/ios/WebPageIOS.mm:
2948 (WebKit::WebPage::replaceSelectedText):
2950 2014-04-21 Gavin Barraclough <baraclough@apple.com>
2952 Don't use ProcessAssertion on simulator
2953 https://bugs.webkit.org/show_bug.cgi?id=131950
2955 Rubber stamped by Benjamin Poulain
2957 * UIProcess/ios/ProcessAssertion.mm:
2958 (WebKit::ProcessAssertion::ProcessAssertion):
2959 (WebKit::ProcessAssertion::setState):
2961 2014-04-21 Anders Carlsson <andersca@apple.com>
2965 * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
2966 (WebKit::XPCServiceInitializerDelegate::checkEntitlements):
2968 2014-04-21 Anders Carlsson <andersca@apple.com>
2972 * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
2973 (WebKit::XPCServiceInitializer):
2975 2014-04-21 Tim Horton <timothy_horton@apple.com>
2977 [iOS WebKit2] Implement CSS viewport units
2978 https://bugs.webkit.org/show_bug.cgi?id=131863
2979 <rdar://problem/16279088>
2981 Reviewed by Darin Adler.
2983 * UIProcess/API/Cocoa/WKWebView.mm:
2984 (setMinimumLayoutSizeForMinimalUI):
2985 (-[WKWebView _minimumLayoutSizeOverrideForMinimalUI]):
2986 (-[WKWebView _setMinimumLayoutSizeOverrideForMinimalUI:]):
2987 Add _setMinimumLayoutSizeOverrideForMinimalUI:, which pushes said size
2988 down from the client to WebPageIOS, below.
2990 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2991 * UIProcess/WebPageProxy.h:
2992 * UIProcess/ios/WebPageProxyIOS.mm:
2993 (WebKit::WebPageProxy::setMinimumLayoutSizeForMinimalUI):
2994 * WebProcess/WebPage/WebPage.h:
2995 * WebProcess/WebPage/WebPage.messages.in:
2996 * WebProcess/WebPage/ios/WebPageIOS.mm:
2997 (WebKit::WebPage::setMinimumLayoutSizeForMinimalUI):
2998 (WebKit::WebPage::viewportConfigurationChanged):
2999 Update FrameView's viewport size based on the minimum layout size for minimal UI (if we have it)
3000 or the normal minimum layout size, scaled to the page's initial scale.
3002 2014-04-21 Benjamin Poulain <bpoulain@apple.com>
3004 [iOS][WK2] Fix the dynamic viewport update when the viewport's max-scale conflict with the transition
3005 https://bugs.webkit.org/show_bug.cgi?id=131884
3007 Reviewed by Darin Adler.
3009 <rdar://problem/16667291>
3011 * UIProcess/API/Cocoa/WKWebView.mm:
3012 (-[WKWebView _beginAnimatedResizeWithUpdates:]):
3013 It is fairly common to have a viewport configuration with min-scale=1 and max-scale=1.
3014 Since we were only changing the minimumScale for the transition, the target scale was affected
3015 by max-scale. This was breaking the transition from portrait to landscale.
3017 2014-04-21 Benjamin Poulain <bpoulain@apple.com>
3019 [iOS][WK2] Make dynamic viewport size update content aware
3020 https://bugs.webkit.org/show_bug.cgi?id=131874
3022 Reviewed by Tim Horton.
3024 When possible, adjust the scroll position based on the content on dynamic viewport resize.
3026 * WebProcess/WebPage/WebPage.cpp:
3027 (WebKit::WebPage::WebPage):
3028 (WebKit::WebPage::scalePage):
3029 (WebKit::WebPage::pageDidScroll):
3030 * WebProcess/WebPage/WebPage.h:
3031 The scrolling heuristic are not invertible, especially the content heuristic. To have the right
3032 behavior when doing resize without changing the page, we save the old scroll position and restore
3033 it when the content size and scale is restored.
3035 * WebProcess/WebPage/ios/WebPageIOS.mm:
3036 (WebKit::WebPage::dynamicViewportSizeUpdate):
3037 On dynamic update, start by finding what node is at the center of the screen. After the layout, put that
3038 node back in the center.
3040 (WebKit::WebPage::updateVisibleContentRects):
3042 2014-04-21 Anders Carlsson <andersca@apple.com>
3044 Need default WKNavigationDelegate behavior
3045 https://bugs.webkit.org/show_bug.cgi?id=131944
3046 <rdar://problem/15949822>
3048 Reviewed by Dan Bernstein.
3050 Port the WebKit1 default delegate behavior over.
3052 * UIProcess/Cocoa/NavigationState.mm:
3053 (WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
3054 (WebKit::NavigationState::PolicyClient::decidePolicyForResponse):
3056 2014-04-21 Dan Bernstein <mitz@apple.com>
3058 [Cocoa] Expose WebPage::setDefersLoading
3059 https://bugs.webkit.org/show_bug.cgi?id=131943
3061 Reviewed by Anders Carlsson, but he doesn’t like this.
3063 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
3064 (-[WKWebProcessPlugInBrowserContextController _defersLoading]): Added this accessor.
3065 (-[WKWebProcessPlugInBrowserContextController _setDefersLoading:]): Ditto.
3066 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextControllerPrivate.h:
3067 Declared new property _defersLoading.
3069 * WebProcess/WebPage/WebPage.cpp:
3070 (WebKit::WebPage::defersLoading): Added this getter.
3071 * WebProcess/WebPage/WebPage.h:
3073 2014-04-21 Joseph Pecoraro <pecoraro@apple.com>
3075 Remove unused WebKitSystemInterface functions
3076 https://bugs.webkit.org/show_bug.cgi?id=131938
3078 Reviewed by Alexey Proskuryakov.
3080 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3081 (InitWebCoreSystemInterface):
3083 2014-04-21 Anders Carlsson <andersca@apple.com>
3085 Check the com.apple.security.network.client entitlement for all processes
3086 https://bugs.webkit.org/show_bug.cgi?id=131942
3087 <rdar://problem/12354188>
3089 Reviewed by Dan Bernstein.
3091 * NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm:
3092 (WebKit::NetworkServiceInitializerDelegate::NetworkServiceInitializerDelegate):
3093 * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
3094 * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
3095 (WebKit::XPCServiceInitializerDelegate::checkEntitlements):
3097 2014-04-20 Dan Bernstein <mitz@apple.com>
3099 [Cocoa] Remove interfaces in the To Be Removed groups
3100 https://bugs.webkit.org/show_bug.cgi?id=131925
3102 Reviewed by Darin Adler.
3104 * Shared/API/Cocoa/WKRemoteObjectInterface.h: Removed.
3105 * Shared/API/Cocoa/WKRemoteObjectInterface.mm: Removed.
3106 * Shared/API/Cocoa/WKRemoteObjectRegistry.h: Removed.
3107 * Shared/API/Cocoa/WKRemoteObjectRegistry.mm: Removed.
3108 * UIProcess/API/Cocoa/WKProcessPool.mm:
3109 * UIProcess/API/Cocoa/WKProcessPoolConfiguration.h: Removed.
3110 * UIProcess/API/Cocoa/WKProcessPoolConfiguration.mm: Removed.
3111 * UIProcess/API/Cocoa/WKProcessPoolConfigurationPrivate.h: Removed.
3112 * UIProcess/API/Cocoa/WKProcessPoolToBeRemoved.mm: Removed.
3113 * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
3114 * WebKit2.xcodeproj/project.pbxproj:
3115 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInBrowserContextControllerToBeRemoved.mm: Removed.
3116 * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextControllerPrivate.h:
3118 2014-04-20 Dan Bernstein <mitz@apple.com>
3120 [Cocoa] Crash when setting a bundle parameter to nil
3121 https://bugs.webkit.org/show_bug.cgi?id=131917
3123 Reviewed by Sam Weinig.
3125 * UIProcess/API/Cocoa/WKProcessPool.mm:
3126 (-[WKProcessPool _setObject:forBundleParameter:]): If the object is nil, use
3127 -[NSMutableDictionary removeObjectForKey:] rather than -setObject:forKey:.
3129 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
3130 (-[WKWebProcessBundleParameters setParameter:forKey:]): Ditto.
3132 * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
3133 (WebKit::InjectedBundle::setBundleParameter): Unrelatedly, create m_bundleParameters if
3134 needed, as it may have not been created on intialization if no bundle parameters were set
3137 2014-04-20 Dan Bernstein <mitz@apple.com>
3139 [Cocoa] Remove unused -webView:didFinishLoadingNavigation: delegate method
3140 https://bugs.webkit.org/show_bug.cgi?id=131914
3142 Reviewed by Sam Weinig.
3144 * UIProcess/Cocoa/NavigationState.h: Removed flag from m_navigationDelegateMethods struct.
3145 * UIProcess/Cocoa/NavigationState.mm:
3146 (WebKit::NavigationState::setNavigationDelegate): Removed check for whether the method is
3148 (WebKit::NavigationState::LoaderClient::didFinishLoadForFrame): Stopped calling the method
3151 2014-04-19 Anders Carlsson <andersca@apple.com>
3153 Plug-in process crashes if NP_Initialize returns an error the second time it's called
3154 https://bugs.webkit.org/show_bug.cgi?id=131903
3155 <rdar://problem/14355462>
3157 Reviewed by Sam Weinig.
3159 * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
3160 (WebKit::NetscapePluginModule::decrementLoadCount):
3161 Don't try to unload the plug-in if it hasn't been initialized.
3163 2014-04-19 Simon Fraser <simon.fraser@apple.com>
3165 [UI-side compositing] Implement blend modes
3166 https://bugs.webkit.org/show_bug.cgi?id=131891
3167 <rdar://problem/16490085>
3169 Reviewed by Tim Horton.
3171 Implement blend modes with UI-side compositing.
3173 PlatformCALayer::setBlendMode() becomes pure virtual, and overridden in
3174 PlatformCALayerMac and PlatformCALayerRemote.
3175 PlatformCAFilters::setBlendingFiltersOnLayer() now takes a raw platform
3176 layer, so it can be called from the UI process on a CALayer*.
3178 Add BlendMode to LayerProperties, and initialize, encode and decode it,
3179 as well as adding dumping support for blend modes.
3181 * Shared/mac/RemoteLayerTreePropertyApplier.mm:
3182 (WebKit::applyPropertiesToLayer):
3183 * Shared/mac/RemoteLayerTreeTransaction.h:
3184 * Shared/mac/RemoteLayerTreeTransaction.mm:
3185 (WebKit::RemoteLayerTreeTransaction::LayerProperties::LayerProperties):
3186 (WebKit::RemoteLayerTreeTransaction::LayerProperties::encode):
3187 (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
3188 (WebKit::RemoteLayerTreeTextStream::operator<<):
3189 (WebKit::dumpChangedLayers):
3190 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
3191 (WebKit::PlatformCALayerRemote::setBlendMode):
3192 * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
3194 2014-04-19 Joseph Pecoraro <pecoraro@apple.com>
3196 Fix leak of UIScreenEdgePanGestureRecognizer in WKSwipeTransitionController
3197 https://bugs.webkit.org/show_bug.cgi?id=131877
3199 Reviewed by Darin Adler.
3201 * UIProcess/ios/ViewGestureControllerIOS.mm:
3202 (-[WKSwipeTransitionController gestureRecognizerForInteractiveTransition:WithTarget:action:]):
3204 2014-04-19 Dan Bernstein <mitz@apple.com>
3206 Don’t install a source file inside WebProcess.app.
3208 * WebKit2.xcodeproj/project.pbxproj: Removed ViewUpdateDispatcher.messages.in from
3209 WebProcess’s Copy Bundle Resources build phase.
3211 2014-04-19 Darin Adler <darin@apple.com>
3213 [Mac] WebView adjusts the cursor even when another window is in front
3214 https://bugs.webkit.org/show_bug.cgi?id=131898
3215 rdar://problem/14619911
3217 Reviewed by Dan Bernstein.
3219 * UIProcess/API/mac/WKView.mm:
3220 (-[WKView _setCursor:]): Deleted. Moved the code all into PageClientImpl, since none of it
3221 interacts with anything special about a WKView.
3223 * UIProcess/API/mac/WKViewInternal.h: Deleted the _setCursor: method.
3225 * UIProcess/mac/PageClientImpl.mm:
3226 (WebKit::PageClientImpl::setCursor): Added a check that the window is under the cursor
3227 and do nothing if it's not.
3229 2014-04-19 Dan Bernstein <mitz@apple.com>
3231 Use XPC services in the iOS Simulator, but not in Mountain Lion
3232 https://bugs.webkit.org/show_bug.cgi?id=131894
3234 Reviewed by Anders Carlsson.
3236 * Configurations/NetworkService.Development.xcconfig: Defined INFOPLIST_FILE for the
3238 * Configurations/NetworkService.xcconfig: Ditto.
3239 * Configurations/WebContentService.Development.xcconfig: Ditto.
3240 * Configurations/WebContentService.xcconfig: Ditto.
3241 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
3242 (WebKit::systemDirectoryPath): Added this helper function that returns a slash-terminated
3243 path to the System directory in the current runtime.
3244 (WebKit::ProcessLauncher::launchProcess): Changed to use the above function to tell whether
3245 a development version of WebKit2 is being used.
3246 * WebKit2Prefix.h: Set WTF_USE_XPC_SERVICES to 1 when targeting the iOS Simulator, but not
3247 when targeting Mountain Lion.
3249 2014-04-19 Dan Bernstein <mitz@apple.com>
3251 [Cocoa] Crash in -[WKWebProcessPlugInHitTestResult nodeHandle] when nodeHandle() is null
3252 https://bugs.webkit.org/show_bug.cgi?id=131888
3254 Reviewed by Jon Honeycutt.
3256 * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInHitTestResult.mm:
3257 (-[WKWebProcessPlugInHitTestResult nodeHandle]): Added a null check.
3259 2014-04-19 Simon Fraser <simon.fraser@apple.com>
3261 [iOS WK2] Fuzzy layers on sites using perspective and transforms
3262 https://bugs.webkit.org/show_bug.cgi?id=131873
3263 <rdar://problem/16540576>
3265 Reviewed by Sam Weinig.
3267 Always set rasterizationScale on CALayers in the UI process
3268 (as we do for WK1) so that layers are rasterized taking the
3269 device scale into account. We can do unconditionally; this
3270 is benign on layers that CA doesn't rasterize.
3272 * Shared/mac/RemoteLayerTreePropertyApplier.mm:
3273 (WebKit::applyPropertiesToLayer):
3275 2014-04-18 Simon Fraser <simon.fraser@apple.com>
3277 Use 'override' in GraphicsLayerCA
3278 https://bugs.webkit.org/show_bug.cgi?id=131882
3280 Reviewed by Tim Horton.
3284 * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
3286 2014-04-19 Darin Adler <darin@apple.com>
3288 Assertion in WebPage::runModal accesses object after it may have been destroyed
3289 https://bugs.webkit.org/show_bug.cgi?id=131875
3291 Reviewed by Anders Carlsson.
3293 * WebProcess/WebPage/WebPage.cpp:
3294 (WebKit::WebPage::runModal): Ref the WebPage so it's still around so we can
3295 check the m_isRunningModal flag.
3297 2014-04-18 Commit Queue <commit-queue@webkit.org>
3299 Unreviewed, rolling out r167527.
3300 https://bugs.webkit.org/show_bug.cgi?id=131883
3302 Broke 32-bit build (Requested by ap on #webkit).
3306 "[Mac] implement WebKitDataCue"
3307 https://bugs.webkit.org/show_bug.cgi?id=131799
3308 http://trac.webkit.org/changeset/167527
3310 2014-04-18 Eric Carlson <eric.carlson@apple.com>
3312 [Mac] implement WebKitDataCue
3313 https://bugs.webkit.org/show_bug.cgi?id=131799
3315 Reviewed by Dean Jackson.
3317 * Configurations/FeatureDefines.xcconfig: Define ENABLE_DATACUE_VALUE.
3319 2014-04-18 Anders Carlsson <andersca@apple.com>
3321 Keep the WebPageProxy alive for the lifetime of all PageLoadState::Transaction objects
3322 https://bugs.webkit.org/show_bug.cgi?id=131872
3323 <rdar://problem/15758414>
3325 Reviewed by Dan Bernstein.
3327 * UIProcess/PageLoadState.cpp:
3328 (WebKit::PageLoadState::PageLoadState):
3329 (WebKit::PageLoadState::Transaction::Transaction):
3330 (WebKit::PageLoadState::Transaction::~Transaction):
3331 * UIProcess/PageLoadState.h:
3332 (WebKit::PageLoadState::Transaction::Transaction): Deleted.
3333 (WebKit::PageLoadState::Transaction::~Transaction): Deleted.
3334 * UIProcess/WebPageProxy.cpp:
3335 (WebKit::WebPageProxy::WebPageProxy):
3337 2014-04-18 Stephanie Lewis <slewis@apple.com>
3339 We shouldn’t create page throttlers for other pages than WebKit2 pages.
3340 Part of <rdar://problem/16473045> Visibility state counters are often incorrect.
3341 https://bugs.webkit.org/show_bug.cgi?id=131696
3343 Reviewed by Gavin Barraclough.
3345 Page throttlers were being created for SVG images and other page instances that
3346 were not accurately tracking the states that enable and disable page throttling.
3347 Make the throttler an unique ptr and only initialize it for WebKit2.
3349 This also fixes an inefficiency where we would throttle a new page on creation because
3350 we assumed it was visible even if that was not the case.
3352 * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp: Check page throttler exists.
3353 (WebKit::NPRuntimeObjectMap::evaluate):
3354 * WebProcess/WebPage/WebPage.cpp:
3355 (WebKit::WebPage::WebPage): Initialize page throttler for WebKit2 views.
3356 (WebKit::WebPage::mouseEvent): Check page throttler exists.
3357 (WebKit::WebPage::wheelEvent): ditto
3358 (WebKit::WebPage::keyEvent): ditto
3360 2014-04-18 Anders Carlsson <andersca@apple.com>
3362 Don't allow app sandboxed apps without the network client entitlement to launch the network process
3363 https://bugs.webkit.org/show_bug.cgi?id=131868
3364 <rdar://problem/12354188>
3366 Reviewed by Dan Bernstein.
3368 * NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm:
3369 (WebKit::NetworkServiceInitializerDelegate::NetworkServiceInitializerDelegate):
3370 Add a new delegate that implements checkEntitlements().
3372 (NetworkServiceInitializer):
3373 Pass the new delegate to XPCServiceInitializer.
3375 * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
3376 * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
3377 Call checkEntitlements.
3379 (WebKit::XPCServiceInitializerDelegate::checkEntitlements):
3382 (WebKit::XPCServiceInitializerDelegate::hasEntitlement):
3383 Helper function that returns whether a client has the given entitlement.
3385 (WebKit::XPCServiceInitializerDelegate::isClientSandboxed):
3386 Helper function that checks whether the client is sandboxed.
3388 2014-04-18 Alice Barraclough <alice.barraclough@webkit.org>
3390 Find on page - extend API by providing highlighted match index
3391 https://bugs.webkit.org/show_bug.cgi?id=131776
3393 Reviewed by Tim Horton.
3395 * Shared/WebFindOptions.h: Add an option for determining match index.
3397 Plumb through the API layers the addition of a parameter for match index.
3398 * UIProcess/API/APIFindClient.h:
3399 (API::FindClient::didFindString):
3400 * UIProcess/API/C/WKPage.cpp:
3401 (WKPageSetPageFindClient):
3402 * UIProcess/API/Cocoa/WKWebView.mm:
3404 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3406 * UIProcess/API/Cocoa/_WKFindDelegate.h:
3407 * UIProcess/Cocoa/FindClient.h:
3408 * UIProcess/Cocoa/FindClient.mm:
3409 (WebKit::FindClient::setDelegate):
3410 (WebKit::FindClient::didFindString):
3411 * UIProcess/WebFindClient.cpp:
3412 (WebKit::WebFindClient::didFindString):
3413 * UIProcess/WebFindClient.h:
3414 * UIProcess/WebPageProxy.cpp:
3415 (WebKit::WebPageProxy::didFindString):
3416 * UIProcess/WebPageProxy.h:
3417 * UIProcess/WebPageProxy.messages.in:
3419 The actual tracking of the match index is contained in FindController class.
3420 * WebProcess/WebPage/FindController.cpp:
3421 (WebKit::FindController::FindController): Start out as -1, understood to be an undefined index in this context.
3422 (WebKit::FindController::updateFindUIAfterPageScroll):
3423 Perform the calculation of matchCount if the flag for DetermineMatchIndex is on.
3424 If matchCount exceeds max, keep the match index undefined because otherwise the finding could advance
3425 to a point where the index exceeds the match count, legitimately. If matchCount doesn't exceed the max, then make
3426 sure the match index, which had been being incremented or decremented blindly back in findString(), is normalized
3427 to be less than match count.
3428 (WebKit::FindController::findString):
3429 If there is a user selection existing on the page, the next occurence of the string will be found after that
3430 selection. In that case we still want the index to properly reflect its ordinal position within the entire document.
3431 Use findStringMatchingRanges to provide the match index, and set a flag that prevents the match index from being
3432 blindly incremented or decremented later. After findString() is actually called on the page, increment or decrement
3433 the find index under specific conditions.
3434 (WebKit::FindController::hideFindIndicator): Reset match index when find UI goes away.
3435 * WebProcess/WebPage/FindController.h: Add m_foundStringMatchIndex to private variables.
3436 * WebProcess/WebPage/ios/FindControllerIOS.mm:
3437 (WebKit::FindController::hideFindIndicator): Reset match index when find UI goes away.
3439 2014-04-18 Joseph Pecoraro <pecoraro@apple.com>
3441 Correct some issues small issues in WK2 file upload InjectedBundle APIs
3442 https://bugs.webkit.org/show_bug.cgi?id=131852
3444 Reviewed by Dan Bernstein.
3446 * WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h:
3447 (API::InjectedBundle::PageUIClient::shouldGenerateFileForUpload):
3448 The default return value, meaning no, should return the null string. The
3449 result is checked later, and null string is a special value meaning no.
3451 * WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp:
3452 (WebKit::InjectedBundlePageUIClient::generateFileForUpload):
3453 Pre-check for the correct client function we will use.
3455 2014-04-18 Andy Estes <aestes@apple.com>
3457 [iOS] REGRESSION (r167039): WebKit incorrectly sets a background process assertion state when displaying a PDF
3458 https://bugs.webkit.org/show_bug.cgi?id=131860
3459 <rdar://problem/16631282>
3461 Reviewed by Tim Horton.
3463 We were basing our process assertion state on whether or not the
3464 process had a WKContentView in a window, but when displaying a PDF
3465 we've removed the WKContentView from the window. Base this decision
3466 instead on whether or not the WKWebView is in the window.
3468 * UIProcess/API/Cocoa/WKWebView.mm:
3469 (-[WKWebView didMoveToWindow]):
3470 * UIProcess/ios/PageClientImplIOS.mm:
3471 (WebKit::PageClientImpl::isViewInWindow):
3473 2014-04-18 Anders Carlsson <andersca@apple.com>
3475 Address a couple of review comments
3476 https://bugs.webkit.org/show_bug.cgi?id=131856
3478 Reviewed by Dan Bernstein.
3480 * UIProcess/API/Cocoa/WKNavigationAction.h:
3481 * UIProcess/API/Cocoa/WKNavigationDelegate.h:
3482 * UIProcess/API/Cocoa/WKPreferences.h:
3483 * UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
3484 * UIProcess/API/Cocoa/WKWebView.h:
3486 2014-04-18 Anders Carlsson <andersca@apple.com>
3488 Handle pluginOrigin being null
3489 https://bugs.webkit.org/show_bug.cgi?id=131849
3490 <rdar://problem/16655898>
3492 Reviewed by Alexey Proskuryakov.
3494 * WebProcess/WebProcess.cpp:
3495 (WebKit::WebProcess::shouldPlugInAutoStartFromOrigin):
3497 2014-04-18 Dan Bernstein <mitz@apple.com>
3499 [Cocoa] Add a navigation delegate method corresponding to didFinishDocumentLoadForFrame for the main frame
3500 https://bugs.webkit.org/show_bug.cgi?id=131847
3502 Reviewed by Anders Carlsson.
3504 * UIProcess/API/APILoaderClient.h:
3505 (API::LoaderClient::didFinishDocumentLoadForFrame): Added a navigationID parameter.
3506 * UIProcess/API/C/WKPage.cpp:
3507 (WKPageSetPageLoaderClient): Updated for the above change in paramerers.
3508 * UIProcess/API/Cocoa/WKNavigationDelegatePrivate.h: Declared new delegate method.
3509 * UIProcess/Cocoa/NavigationState.h: Declare override of didFinishDocumentLoadForFrame.
3510 * UIProcess/Cocoa/NavigationState.mm:
3511 (WebKit::NavigationState::setNavigationDelegate): Initialize
3512 webViewNavigationDidFinishDocumentLoad flag in the delegate methods struct.
3513 (WebKit::NavigationState::LoaderClient::didFinishDocumentLoadForFrame): Added override
3514 of the client function which calls the delegate.
3515 * UIProcess/WebPageProxy.cpp:
3516 (WebKit::WebPageProxy::didFinishDocumentLoadForFrame): Get and pass the navigation ID to
3518 * UIProcess/WebPageProxy.h: Added navigationID parameter.
3519 * UIProcess/WebPageProxy.messages.in: Ditto.
3520 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3521 (WebKit::WebFrameLoaderClient::dispatchDidFinishDocumentLoad): Get and send the navigation
3522 ID to the UI process.
3524 2014-04-18 Philippe Normand <pnormand@igalia.com>
3526 Remove NETWORK_INFO support
3527 https://bugs.webkit.org/show_bug.cgi?id=131841
3529 Reviewed by Gyuyoung Kim.
3532 * PlatformEfl.cmake:
3533 * Shared/API/c/WKBase.h:
3534 * Shared/APIObject.h:
3535 * Shared/WebNetworkInfo.cpp: Removed.
3536 * Shared/WebNetworkInfo.h: Removed.
3537 * UIProcess/API/C/WKAPICast.h:
3538 * UIProcess/API/C/WKContext.cpp:
3539 (WKContextGetNetworkInfoManager): Deleted.
3540 * UIProcess/API/C/WKContext.h:
3541 * UIProcess/API/C/WKNetworkInfo.cpp: Removed.
3542 * UIProcess/API/C/WKNetworkInfo.h: Removed.
3543 * UIProcess/API/C/WKNetworkInfoManager.cpp: Removed.
3544 * UIProcess/API/C/WKNetworkInfoManager.h: Removed.
3545 * UIProcess/API/efl/ewk_context.cpp:
3546 (EwkContext::EwkContext):
3547 * UIProcess/API/efl/ewk_context_private.h:
3548 * UIProcess/WebContext.cpp:
3549 (WebKit::WebContext::WebContext):
3550 * UIProcess/WebContext.h:
3551 * UIProcess/WebNetworkInfoManagerProxy.cpp: Removed.
3552 * UIProcess/WebNetworkInfoManagerProxy.h: Removed.
3553 * UIProcess/WebNetworkInfoManagerProxy.messages.in: Removed.
3554 * UIProcess/WebNetworkInfoProvider.cpp: Removed.
3555 * UIProcess/WebNetworkInfoProvider.h: Removed.
3556 * UIProcess/efl/NetworkInfoProvider.cpp: Removed.
3557 * UIProcess/efl/NetworkInfoProvider.h: Removed.
3558 * WebProcess/NetworkInfo/WebNetworkInfoManager.cpp: Removed.
3559 * WebProcess/NetworkInfo/WebNetworkInfoManager.h: Removed.
3560 * WebProcess/NetworkInfo/WebNetworkInfoManager.messages.in: Removed.
3561 * WebProcess/WebCoreSupport/WebNetworkInfoClient.cpp: Removed.
3562 * WebProcess/WebCoreSupport/WebNetworkInfoClient.h: Removed.
3563 * WebProcess/WebPage/WebPage.cpp:
3564 (WebKit::WebPage::WebPage):
3565 * WebProcess/WebProcess.cpp:
3566 (WebKit::WebProcess::WebProcess):
3568 2014-04-17 Daniel Bates <dabates@apple.com>
3570 [iOS] Hook up screen.{availHeight, availWidth, height, width}
3571 https://bugs.webkit.org/show_bug.cgi?id=131821
3572 <rdar://problem/16413795>
3574 Reviewed by Benjamin Poulain and Tim Horton.
3576 Implement WebKit2-specific support infrastructure.
3578 Additionally substitute "screenSize" for "viewporScreenSize" to make the code more understandable.
3580 * Shared/WebPageCreationParameters.cpp:
3581 (WebKit::WebPageCreationParameters::encode): Modified to encode the available screen size
3583 (WebKit::WebPageCreationParameters::decode): Modified to decode the available screen size
3585 * Shared/WebPageCreationParameters.h:
3586 * UIProcess/WebPageProxy.cpp:
3587 (WebKit::WebPageProxy::creationParameters): Initialize the available screen size
3589 * UIProcess/WebPageProxy.h:
3590 * UIProcess/ios/WebPageProxyIOS.mm:
3591 (WebKit::WebPageProxy::screenSize): Renamed; formerly named viewportScreenSize.
3592 (WebKit::WebPageProxy::availableScreenSize): Added.
3593 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3594 (WebKit::WebChromeClient::screenSize): Renamed; formerly named viewportScreenSize.
3595 (WebKit::WebChromeClient::availableScreenSize): Added; turns around and calls WebPage::availableScreenSize().
3596 * WebProcess/WebCoreSupport/WebChromeClient.h:
3597 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3598 (InitWebCoreSystemInterface): Hook up WebKit System Interface function WKGetAvailableScreenSize.
3599 * WebProcess/WebPage/WebPage.cpp:
3600 (WebKit::WebPage::WebPage): Initialize available screen size instance variable.
3601 * WebProcess/WebPage/WebPage.h:
3602 * WebProcess/WebPage/ios/WebPageIOS.mm:
3603 (WebKit::WebPage::screenSize):
3604 (WebKit::WebPage::availableScreenSize):
3606 2014-04-17 Anders Carlsson <andersca@apple.com>
3608 Remove unused API enums
3609 https://bugs.webkit.org/show_bug.cgi?id=131836
3611 Reviewed by Tim Horton.
3613 * UIProcess/API/Cocoa/WKNavigationDelegate.h:
3615 * UIProcess/Cocoa/NavigationState.mm:
3616 (WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
3617 (WebKit::NavigationState::PolicyClient::decidePolicyForResponse):
3619 2014-04-17 Brent Fulgham <bfulgham@apple.com>
3621 Make RenderLayerBacking get the timingFunction of the correct animation.
3622 https://bugs.webkit.org/show_bug.cgi?id=100632
3624 Reviewed by Simon Fraser.
3626 * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
3627 (IPC::ArgumentCoder<GraphicsLayerAnimation>::decode): Update for new signatures for
3628 FloatAnimationValue, TransformAnimationValue, etc.
3630 2014-04-17 Enrica Casucci <enrica@apple.com>
3632 [iOS WebKit2] support replacements for misspelled words.
3633 https://bugs.webkit.org/show_bug.cgi?id=131827
3634 <rdar://problem/16319657>
3636 Reviewed by Benjamin Poulain.
3638 This is the first part of the work to add support for replacements.
3639 It handles _promptForReplace in canPerformAction to decide
3640 whether to show the Replace button in the menu and add the
3641 implementation of the replace action.
3643 * Shared/EditorState.cpp:
3644 (WebKit::EditorState::encode):
3645 (WebKit::EditorState::decode):
3646 * Shared/EditorState.h:
3647 (WebKit::EditorState::EditorState):
3648 * UIProcess/WebPageProxy.h:
3649 * UIProcess/ios/WKContentViewInteraction.mm:
3650 (-[WKContentView selectedText]):
3651 (-[WKContentView replaceText:withText:]):
3652 (-[WKContentView _promptForReplace:]):
3653 (-[WKContentView replace:]):
3654 (-[WKContentView canPerformAction:withSender:]):
3655 (-[WKContentView selectWordForReplacement]): This is called
3656 by UIKit when the user taps on a mispelled word to select it.
3657 * UIProcess/ios/WebPageProxyIOS.mm:
3658 (WebKit::WebPageProxy::replaceSelectedText):
3659 * WebProcess/WebPage/WebPage.cpp:
3660 (WebKit::WebPage::WebPage):
3661 (WebKit::WebPage::editorState):
3662 * WebProcess/WebPage/WebPage.h:
3663 * WebProcess/WebPage/WebPage.messages.in:
3664 * WebProcess/WebPage/ios/WebPageIOS.mm:
3665 (WebKit::WebPage::selectWithGesture): Removed m_shouldReturnWordForSelection.
3666 We now return always the word corresponding to the caret selection or
3667 the selected text up to a maximum of 200 characters.
3668 (WebKit::WebPage::extendSelection):
3669 (WebKit::WebPage::replaceSelectedText):
3671 2014-04-17 Tim Horton <timothy_horton@apple.com>
3673 [iOS] REGRESSION (r166975): WKPDFView is broken
3674 https://bugs.webkit.org/show_bug.cgi?id=131828
3676 Reviewed by Simon Fraser.
3678 * UIProcess/API/Cocoa/WKWebView.mm:
3679 (-[WKWebView _didCommitLayerTree:WebKit::]):
3680 Bail from updating the scroll view parameters from the layer tree update
3681 while it's being managed by a custom content view.
3682 We'll get any changes again in the next commit after removing the custom
3683 content view (and painting the new page) anyway, so this should be OK.
3685 2014-04-17 Pratik Solanki <psolanki@apple.com>
3687 _webProcessIdentifier should return 0 if the web process crashed
3688 https://bugs.webkit.org/show_bug.cgi?id=131813
3689 <rdar://problem/16650605>
3691 Reviewed by Anders Carlsson.
3693 * UIProcess/API/Cocoa/WKWebView.mm:
3694 (-[WKWebView _hasWebProcess]):
3695 * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3697 2014-04-17 Darin Adler <darin@apple.com>
3699 Remove use of deprecatedDeleteAllValues in NPRemoteObjectMap::pluginDestroyed
3700 https://bugs.webkit.org/show_bug.cgi?id=122496
3702 Reviewed by Brent Fulgham.
3704 * Shared/Plugins/NPRemoteObjectMap.cpp:
3705 (WebKit::NPRemoteObjectMap::pluginDestroyed): Use new-style code and write the
3706 deprecatedDeleteAllValues function out using a loop. Might be nice to return here
3707 and use unique_ptr instead some day, but I tried that before and got it wrong, so
3708 lets do that another time.
3710 2014-04-17 Darin Adler <darin@apple.com>
3712 Add separate flag for IndexedDatabase in workers since the current implementation is not threadsafe
3713 https://bugs.webkit.org/show_bug.cgi?id=131785
3714 rdar://problem/16003108
3716 Reviewed by Brady Eidson.
3718 * Configurations/FeatureDefines.xcconfig: Added INDEXED_DATABASE_IN_WORKERS.
3720 2014-04-17 Dan Bernstein <mitz@apple.com>
3722 WebKit2 part of <rdar://problem/16601336> [Cocoa] _userInitiated is always NO in WKNavigationAction passed to -webView:createWebViewWithConfiguration:forNavigationAction:windowFeatures:
3723 https://bugs.webkit.org/show_bug.cgi?id=131783
3725 Reviewed by Tim Horton.
3727 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3728 (WebKit::WebChromeClient::createWindow): Set the isProcessingUserGesture field of
3729 the NavigationActionData to the corresponding value in the NavigationAction.
3730 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3731 (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction): Ditto.
3732 (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Ditto.
3734 2014-04-16 Benjamin Poulain <bpoulain@apple.com>
3736 [iOS][WK2] Fix the DidCommitLoad initial scrolling position
3737 https://bugs.webkit.org/show_bug.cgi?id=131780
3739 Reviewed by Jon Honeycutt.
3741 * UIProcess/API/Cocoa/WKWebView.mm:
3742 (-[WKWebView _didCommitLayerTree:]):
3743 That code is older than _obscuredInsets and used the contentInsets as a workaround.
3745 2014-04-16 Benjamin Poulain <bpoulain@apple.com>
3747 [iOS][WK2] Fix annoying scrolling bugs
3748 https://bugs.webkit.org/show_bug.cgi?id=131722
3750 Reviewed by Simon Fraser.
3752 * UIProcess/API/Cocoa/WKWebView.mm:
3753 (-[WKWebView _scrollToContentOffset:WebCore::]):
3754 We are scrolling at the wrong position when we have the "small obscured insets".
3756 2014-04-16 Gavin Barraclough <baraclough@apple.com>
3758 On iOS keep network process running using a process assertion rather than a boost
3759 https://bugs.webkit.org/show_bug.cgi?id=131779
3761 Reviewed by Benjamin Poulain.
3763 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
3764 (WebKit::connectToService):
3765 - No need to leak a boost onto the NetworkProcess on iOS.
3766 * UIProcess/Network/NetworkProcessProxy.cpp:
3767 (WebKit::NetworkProcessProxy::didFinishLaunching):
3768 - Take a ProcessAssertion on the NetworkProcess.
3769 * UIProcess/Shared/ChildProcessProxy.h:
3770 - Added m_assertion.
3771 * UIProcess/WebProcessProxy.h:
3772 - Removed m_assertion.
3773 * UIProcess/ios/ProcessAssertion.h: Added.
3774 - Added - refactored from WebProcessProxy.h.
3775 * UIProcess/ios/ProcessAssertion.mm: Added.
3776 (WebKit::ProcessAssertion::ProcessAssertion):
3777 (WebKit::ProcessAssertion::setState):
3778 - Added - refactored from WebProcessProxyIOS.mm.
3779 * UIProcess/ios/WebProcessProxyIOS.mm:
3780 (WebKit::WebProcessProxy::updateProcessState):
3781 - Code refactored out to ProcessAssertion.mm.
3782 * WebKit2.xcodeproj/project.pbxproj:
3785 2014-04-16 Benjamin Poulain <bpoulain@apple.com>
3787 [iOS][WK2] Improve the approximation of the scroll position of the dynamic viewport size updates
3788 https://bugs.webkit.org/show_bug.cgi?id=131720
3790 Reviewed by Tim Horton.
3792 * UIProcess/API/Cocoa/WKWebView.mm:
3793 (-[WKWebView _scrollToContentOffset:]):
3794 The scrolling tree was forcing scroll at the wrong scale during the transition.
3796 (-[WKWebView _setMinimumLayoutSizeOverride:]):
3797 This was left out by accident. The WebProcess was getting the new layout size twice, making
3798 WebPage::dynamicViewportSizeUpdate() very confused when the content size changes.
3800 * WebProcess/WebPage/ios/WebPageIOS.mm:
3801 (WebKit::WebPage::dynamicViewportSizeUpdate):
3802 Add scrolling adjustment for the dynamic relayout case:
3803 -Sticky top and bottom like the UIProcess.
3804 -Keep the same relative position of the unobscured rect's center.
3806 Also fix a bug in the horizontal and vertical adjustments: the code was using the exposed rect
3807 instead of the unobscured rect, which made the adjustments off by the size of the obscured insets.
3809 The type is changed from double to float since ARMv7 has a grudge against double.
3811 2014-04-16 Benjamin Poulain <bpoulain@apple.com>
3813 [iOS][WK2] Do not update the visible content rects when setting the same obscured insets multiple times
3814 https://bugs.webkit.org/show_bug.cgi?id=131633
3816 Reviewed by Darin Adler.
3818 We should avoid computing the visible content rects when not needed.
3820 * UIProcess/API/Cocoa/WKWebView.mm:
3821 (-[WKWebView _setObscuredInsets:]):
3823 2014-04-16 Zan Dobersek <zdobersek@igalia.com>
3825 Make IPC::Arguments a variadic template
3826 https://bugs.webkit.org/show_bug.cgi?id=131684
3828 Reviewed by Darin Adler.
3830 Make IPC::Arguments a variadic template that uses the template parameter pack to further
3831 define the std::tuple ValueType and is used to define the std::tuple container of the
3832 values passed into the container.
3834 * Platform/IPC/Arguments.h:
3835 (IPC::Arguments::Arguments):
3836 (IPC::Arguments::encode):
3837 (IPC::Arguments::decode):
3838 (IPC::Arguments0::encode): Deleted.
3839 (IPC::Arguments0::decode): Deleted.
3840 (IPC::Arguments1::Arguments1): Deleted.
3841 (IPC::Arguments1::encode): Deleted.
3842 (IPC::Arguments1::decode): Deleted.
3843 (IPC::Arguments2::Arguments2): Deleted.
3844 (IPC::Arguments2::encode): Deleted.
3845 (IPC::Arguments2::decode): Deleted.
3846 (IPC::Arguments3::Arguments3): Deleted.
3847 (IPC::Arguments3::encode): Deleted.
3848 (IPC::Arguments3::decode): Deleted.
3849 (IPC::Arguments4::Arguments4): Deleted.
3850 (IPC::Arguments4::encode): Deleted.
3851 (IPC::Arguments4::decode): Deleted.
3852 (IPC::Arguments5::Arguments5): Deleted.
3853 (IPC::Arguments5::encode): Deleted.
3854 (IPC::Arguments5::decode): Deleted.
3855 (IPC::Arguments6::Arguments6): Deleted.
3856 (IPC::Arguments6::encode): Deleted.
3857 (IPC::Arguments6::decode): Deleted.
3858 (IPC::Arguments7::Arguments7): Deleted.
3859 (IPC::Arguments7::encode): Deleted.
3860 (IPC::Arguments7::decode): Deleted.
3861 (IPC::Arguments8::Arguments8): Deleted.
3862 (IPC::Arguments8::encode): Deleted.
3863 (IPC::Arguments8::decode): Deleted.
3864 (IPC::Arguments10::Arguments10): Deleted.
3865 (IPC::Arguments10::encode): Deleted.
3866 (IPC::Arguments10::decode): Deleted.
3867 * Scripts/webkit2/LegacyMessages-expected.h:
3868 * Scripts/webkit2/Messages-expected.h:
3869 * Scripts/webkit2/messages.py: Clean up the code a bit.
3870 (reply_parameter_type):
3874 (arguments_type_old): Deleted.
3875 (base_class): Deleted.
3876 (delayed_reply_type): Deleted.
3878 2014-04-16 Tim Horton <timothy_horton@apple.com>
3880 Deduplicate LayerTreeContext
3881 https://bugs.webkit.org/show_bug.cgi?id=131773
3883 Reviewed by Simon Fraser.
3885 There are three identical implementations, one for each platform, for no reason.
3888 * PlatformEfl.cmake:
3889 * PlatformGTK.cmake:
3890 * Shared/LayerTreeContext.cpp: Renamed from Source/WebKit2/Shared/mac/LayerTreeContextMac.mm.
3891 (WebKit::LayerTreeContext::LayerTreeContext):
3892 (WebKit::LayerTreeContext::~LayerTreeContext):
3893 (WebKit::LayerTreeContext::encode):
3894 (WebKit::LayerTreeContext::decode):
3895 (WebKit::LayerTreeContext::isEmpty):
3896 (WebKit::operator==):
3897 * Shared/LayerTreeContext.h:
3898 (WebKit::operator!=): Deleted.
3899 * Shared/efl/LayerTreeContextEfl.cpp: Removed.
3900 * Shared/gtk/LayerTreeContextGtk.cpp: Removed.
3901 * WebKit2.xcodeproj/project.pbxproj:
3902 * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
3903 (WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
3904 * WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
3905 (WebKit::LayerTreeHostGtk::initialize):
3907 2014-04-16 Tim Horton <timothy_horton@apple.com>
3909 Don't build LayerTreeHost on Mac (and clean it up)
3910 https://bugs.webkit.org/show_bug.cgi?id=131769
3912 Reviewed by Simon Fraser.
3914 * WebKit2.xcodeproj/project.pbxproj:
3915 Don't include it in the project.
3917 * WebProcess/InjectedBundle/InjectedBundle.cpp:
3918 (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
3919 * WebProcess/WebPage/CoordinatedGraphics/CoordinatedDrawingArea.cpp:
3920 (WebKit::CoordinatedDrawingArea::updatePreferences):
3921 * WebProcess/WebPage/DrawingAreaImpl.cpp:
3922 (WebKit::DrawingAreaImpl::updatePreferences):
3923 * WebProcess/WebPage/LayerTreeHost.h:
3924 (WebKit::LayerTreeHost::setLayerHostingMode): Deleted.
3925 (WebKit::LayerTreeHost::supportsAcceleratedCompositing): Deleted.
3926 * WebProcess/WebPage/WebPage.cpp:
3927 (WebKit::WebPage::updatePreferences):
3928 * WebProcess/WebPage/ios/WebPageIOS.mm:
3929 Get rid of LayerTreeHost::supportsAcceleratedCompositing, which always returns true everywhere.
3930 Remove some LayerTreeHost.h includes.
3931 Remove LayerTreeHost::setLayerHostingMode, which is PLATFORM(COCOA) and not needed.
3933 2014-04-16 Simon Fraser <simon.fraser@apple.com>
3935 Failing to decode a layer tree commit message resulted in silent and mysterious failure
3936 https://bugs.webkit.org/show_bug.cgi?id=131766
3937 <rdar://problem/16520894>
3939 Reviewed by Sam Weinig.
3941 If the message decode failed, we should have already marked the message as invalid.
3942 Failing to do so indicates in a decode code coding error.
3944 * Platform/IPC/HandleMessage.h:
3945 (IPC::handleMessage):
3946 (IPC::handleMessageVariadic):
3947 (IPC::handleMessageDelayed):
3949 2014-04-16 Tim Horton <timothy_horton@apple.com>
3951 Minor include sanity in WebPage.h
3952 https://bugs.webkit.org/show_bug.cgi?id=131752
3954 Reviewed by Simon Fraser.
3956 * WebProcess/WebPage/WebPage.h:
3957 Remove a bunch of unnecessary includes.
3958 Un-indent some stuff.
3960 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
3961 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3962 * WebProcess/WebPage/FindController.cpp:
3963 * WebProcess/WebPage/WebPage.cpp:
3964 * WebProcess/WebPage/mac/WebPageMac.mm:
3965 Add back more specific includes, into implementation files.
3967 * WebProcess/WebPage/WebUndoStep.cpp:
3968 (WebKit::WebUndoStep::~WebUndoStep):
3969 * WebProcess/WebPage/WebUndoStep.h:
3970 Add an out-of-line destructor.
3972 2014-04-16 Gavin Barraclough <baraclough@apple.com>
3974 REGRESSION: PCE.js is 20x slower in WebKit2 because timers are throttled
3975 https://bugs.webkit.org/show_bug.cgi?id=131189
3977 Unreviewed rollout of r166754
3979 This change is no longer necessary.
3981 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
3982 (WebKit::connectToService):
3984 2014-04-16 Alexey Proskuryakov <ap@apple.com>
3986 Updating tests after bug 131721, [GTK] Fix unused parameter warnings.
3988 * Scripts/webkit2/LegacyMessageReceiver-expected.cpp:
3989 (WebKit::WebPage::didReceiveWebPageMessage):
3990 (WebKit::WebPage::didReceiveSyncWebPageMessage):
3991 * Scripts/webkit2/MessageReceiver-expected.cpp:
3992 (WebKit::WebPage::didReceiveMessage):
3993 (WebKit::WebPage::didReceiveSyncMessage):
3995 2014-04-16 Brendan Long <b.long@cablelabs.com>
3997 [GTK] Fix unused parameter warnings
3998 https://bugs.webkit.org/show_bug.cgi?id=131721
4000 Reviewed by Darin Adler.
4002 * Scripts/webkit2/messages.py:
4003 (generate_message_handler): Add UNUSED_PARAM() for a couple parameters which aren't always used.
4004 * Shared/WebCoreArgumentCoders.cpp:
4005 (IPC::ArgumentCoder<LinearTimingFunction>::decode): Remove unused parameters.
4006 * WebProcess/InjectedBundle/APIInjectedBundleFormClient.h:
4007 (API::InjectedBundle::FormClient::textDidChangeInTextField): Same.
4008 (API::InjectedBundle::FormClient::willSubmitForm): Same.
4009 (API::InjectedBundle::FormClient::willSendSubmitEvent): Same.
4010 * WebProcess/Network/NetworkProcessConnection.cpp:
4011 (WebKit::NetworkProcessConnection::didReceiveSyncMessage): Same.
4013 2014-04-16 Tim Horton <timothy_horton@apple.com>
4015 Accidentally included some style-checker-testing changes in the last commit.
4017 * WebProcess/Plugins/PDF/PDFPlugin.mm:
4018 (WebKit::PDFPlugin::attemptToUnlockPDF):
4019 (WebKit::PDFPlugin::updatePageAndDeviceScaleFactors):
4021 2014-04-16 Tim Horton <timothy_horton@apple.com>
4023 Fix some style checker complaints in PDFPlugin
4024 https://bugs.webkit.org/show_bug.cgi?id=131706
4026 Reviewed by Darin Adler.
4028 * WebProcess/Plugins/PDF/PDFPlugin.mm:
4029 (-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:]):
4030 (-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:forParameter:]):
4031 (-[WKPDFPluginAccessibilityObject accessibilityAttributeNames]):
4032 (WebKit::PDFPlugin::attemptToUnlockPDF):
4033 (WebKit::PDFPlugin::updatePageAndDeviceScaleFactors):
4034 (WebKit::PDFPlugin::isEditingCommandEnabled):
4035 (WebKit::PDFPlugin::nextMatchForString):
4036 (WebKit::PDFPlugin::handleWheelEvent):
4037 (WebKit::PDFPlugin::liveData):
4039 2014-04-15 Dan Bernstein <mitz@apple.com>
4041 [Cocoa] Add a form delegate method corresponding to willSubmitForm
4042 https://bugs.webkit.org/show_bug.cgi?id=131718