Title: [204458] trunk/Source/WebKit2
Revision
204458
Author
[email protected]
Date
2016-08-14 17:02:31 -0700 (Sun, 14 Aug 2016)

Log Message

[Cocoa] Remove deprecated _WKFormDelegate
https://bugs.webkit.org/show_bug.cgi?id=160848

Reviewed by Anders Carlsson.

* Shared/API/Cocoa/WebKitPrivate.h: Removed #import.
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _formDelegate]): Moved into WKBinaryCompatibilityIOS10 cateogry implementation,
  chaged type to id <_WKInputDelegate>.
(-[WKWebView _setFormDelegate:]): Ditto.
* UIProcess/API/Cocoa/WKWebViewPrivate.h: Removed property declaration.
* UIProcess/API/Cocoa/_WKFormDelegate.h: Removed.
* WebKit2.xcodeproj/project.pbxproj: Removed reference to header.
* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h: Fixed comment.

Modified Paths

Removed Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (204457 => 204458)


--- trunk/Source/WebKit2/ChangeLog	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/ChangeLog	2016-08-15 00:02:31 UTC (rev 204458)
@@ -1,3 +1,20 @@
+2016-08-14  Dan Bernstein  <[email protected]>
+
+        [Cocoa] Remove deprecated _WKFormDelegate
+        https://bugs.webkit.org/show_bug.cgi?id=160848
+
+        Reviewed by Anders Carlsson.
+
+        * Shared/API/Cocoa/WebKitPrivate.h: Removed #import.
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView _formDelegate]): Moved into WKBinaryCompatibilityIOS10 cateogry implementation,
+          chaged type to id <_WKInputDelegate>.
+        (-[WKWebView _setFormDelegate:]): Ditto.
+        * UIProcess/API/Cocoa/WKWebViewPrivate.h: Removed property declaration.
+        * UIProcess/API/Cocoa/_WKFormDelegate.h: Removed.
+        * WebKit2.xcodeproj/project.pbxproj: Removed reference to header.
+        * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h: Fixed comment.
+
 2016-08-14  Daniel Bates  <[email protected]>
 
         Fix compiler errors when building iOS WebKit using the iOS 10 beta SDK

Modified: trunk/Source/WebKit2/Shared/API/Cocoa/WebKitPrivate.h (204457 => 204458)


--- trunk/Source/WebKit2/Shared/API/Cocoa/WebKitPrivate.h	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/Shared/API/Cocoa/WebKitPrivate.h	2016-08-15 00:02:31 UTC (rev 204458)
@@ -32,7 +32,6 @@
 #import <WebKit/_WKActivatedElementInfo.h>
 #import <WebKit/_WKElementAction.h>
 #import <WebKit/_WKFocusedElementInfo.h>
-#import <WebKit/_WKFormDelegate.h>
 #import <WebKit/_WKFormInputSession.h>
 #import <WebKit/_WKInputDelegate.h>
 #import <WebKit/_WKProcessPoolConfiguration.h>

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm (204457 => 204458)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2016-08-15 00:02:31 UTC (rev 204458)
@@ -76,7 +76,6 @@
 #import "WebViewImpl.h"
 #import "_WKDiagnosticLoggingDelegate.h"
 #import "_WKFindDelegate.h"
-#import "_WKFormDelegate.h"
 #import "_WKFrameHandleInternal.h"
 #import "_WKHitTestResultInternal.h"
 #import "_WKInputDelegate.h"
@@ -3721,11 +3720,6 @@
     return _inputDelegate.getAutoreleased();
 }
 
-- (id <_WKFormDelegate>)_formDelegate
-{
-    return (id <_WKFormDelegate>)[self _inputDelegate];
-}
-
 - (void)_setInputDelegate:(id <_WKInputDelegate>)inputDelegate
 {
     _inputDelegate = inputDelegate;
@@ -3789,11 +3783,6 @@
         _page->setFormClient(nullptr);
 }
 
-- (void)_setFormDelegate:(id <_WKFormDelegate>)formDelegate
-{
-    [self _setInputDelegate:(id <_WKInputDelegate>)formDelegate];
-}
-
 - (BOOL)_isDisplayingStandaloneImageDocument
 {
     if (auto* mainFrame = _page->mainFrame())
@@ -4653,6 +4642,20 @@
 
 @end
 
+@implementation WKWebView (WKBinaryCompatibilityWithIOS10)
+
+- (id <_WKInputDelegate>)_formDelegate
+{
+    return self._inputDelegate;
+}
+
+- (void)_setFormDelegate:(id <_WKInputDelegate>)formDelegate
+{
+    self._inputDelegate = formDelegate;
+}
+
+@end
+
 #if USE(APPLE_INTERNAL_SDK)
 #import <WebKitAdditions/WKWebViewAdditionsAfter.mm>
 #endif

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h (204457 => 204458)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h	2016-08-15 00:02:31 UTC (rev 204458)
@@ -62,7 +62,6 @@
 @protocol WKHistoryDelegatePrivate;
 @protocol _WKDiagnosticLoggingDelegate;
 @protocol _WKFindDelegate;
-@protocol _WKFormDelegate;
 @protocol _WKInputDelegate;
 
 @interface WKWebView (WKPrivate)
@@ -231,7 +230,6 @@
 - (void)_countStringMatches:(NSString *)string options:(_WKFindOptions)options maxCount:(NSUInteger)maxCount;
 - (void)_hideFindUI;
 
-@property (nonatomic, weak, setter=_setFormDelegate:) id <_WKFormDelegate> _formDelegate WK_API_DEPRECATED_WITH_REPLACEMENT("_inputDelegate", macosx(10.10, WK_MAC_TBA), ios(8.0, WK_IOS_TBA));
 @property (nonatomic, weak, setter=_setInputDelegate:) id <_WKInputDelegate> _inputDelegate WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 
 @property (nonatomic, readonly, getter=_isDisplayingStandaloneImageDocument) BOOL _displayingStandaloneImageDocument;

Deleted: trunk/Source/WebKit2/UIProcess/API/Cocoa/_WKFormDelegate.h (204457 => 204458)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/_WKFormDelegate.h	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/_WKFormDelegate.h	2016-08-15 00:02:31 UTC (rev 204458)
@@ -1,39 +0,0 @@
-/*
- * Copyright (C) 2014 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <WebKit/WKFoundation.h>
-
-#if WK_API_ENABLED
-
-#import <WebKit/_WKInputDelegate.h>
-
-/**
- * We are transitioning _WKFormDelegate to _WKInputDelegate. This header is here temporarily for source compatibility and
- * should be removed when we are ready to make the switch.
- */
-@protocol _WKFormDelegate <_WKInputDelegate>
-@end
-
-#endif // WK_API_ENABLED

Modified: trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj (204457 => 204458)


--- trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj	2016-08-15 00:02:31 UTC (rev 204458)
@@ -715,7 +715,6 @@
 		2DF9EEEE1A786EAD00B6CFBE /* APINavigationResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DF9EEED1A786EAD00B6CFBE /* APINavigationResponse.h */; };
 		2DFC7DBB1BCCC19500C1548C /* WebViewImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DFC7DB91BCCC19500C1548C /* WebViewImpl.h */; };
 		2DFC7DBC1BCCC19500C1548C /* WebViewImpl.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2DFC7DBA1BCCC19500C1548C /* WebViewImpl.mm */; };
-		2E0B8A7A1BC59A590044B32D /* _WKFormDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 2E0B8A791BC59A590044B32D /* _WKFormDelegate.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		2E7A944A1BBD97C300945547 /* _WKFocusedElementInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 2E7A94491BBD95C600945547 /* _WKFocusedElementInfo.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		31099973146C75A20029DEB9 /* WebNotificationClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 31099971146C759B0029DEB9 /* WebNotificationClient.cpp */; };
 		310999C7146C9E3D0029DEB9 /* WebNotificationClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 31099968146C71F50029DEB9 /* WebNotificationClient.h */; };
@@ -2751,7 +2750,6 @@
 		2DF9EEED1A786EAD00B6CFBE /* APINavigationResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APINavigationResponse.h; sourceTree = "<group>"; };
 		2DFC7DB91BCCC19500C1548C /* WebViewImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebViewImpl.h; sourceTree = "<group>"; };
 		2DFC7DBA1BCCC19500C1548C /* WebViewImpl.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebViewImpl.mm; sourceTree = "<group>"; };
-		2E0B8A791BC59A590044B32D /* _WKFormDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = _WKFormDelegate.h; sourceTree = "<group>"; };
 		2E7A94491BBD95C600945547 /* _WKFocusedElementInfo.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = _WKFocusedElementInfo.h; sourceTree = "<group>"; };
 		31099968146C71F50029DEB9 /* WebNotificationClient.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebNotificationClient.h; sourceTree = "<group>"; };
 		31099971146C759B0029DEB9 /* WebNotificationClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebNotificationClient.cpp; sourceTree = "<group>"; };
@@ -5145,7 +5143,6 @@
 				005D158E18E4C4EB00734619 /* _WKFindDelegate.h */,
 				2DEAC5CE1AC368BB00A195D8 /* _WKFindOptions.h */,
 				2E7A94491BBD95C600945547 /* _WKFocusedElementInfo.h */,
-				2E0B8A791BC59A590044B32D /* _WKFormDelegate.h */,
 				37A64E5618F38F4600EB30F1 /* _WKFormInputSession.h */,
 				37A64E5418F38E3C00EB30F1 /* _WKInputDelegate.h */,
 				2D790A9C1AD7050D00AB90B3 /* _WKLayoutMode.h */,
@@ -7407,7 +7404,6 @@
 				005D158F18E4C4EB00734619 /* _WKFindDelegate.h in Headers */,
 				2DEAC5CF1AC368BB00A195D8 /* _WKFindOptions.h in Headers */,
 				2E7A944A1BBD97C300945547 /* _WKFocusedElementInfo.h in Headers */,
-				2E0B8A7A1BC59A590044B32D /* _WKFormDelegate.h in Headers */,
 				37A64E5718F38F4600EB30F1 /* _WKFormInputSession.h in Headers */,
 				373D122318A473010066D9CC /* _WKFrameHandle.h in Headers */,
 				373D122718A473F60066D9CC /* _WKFrameHandleInternal.h in Headers */,

Modified: trunk/Source/WebKit2/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h (204457 => 204458)


--- trunk/Source/WebKit2/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h	2016-08-14 23:04:50 UTC (rev 204457)
+++ trunk/Source/WebKit2/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFormDelegatePrivate.h	2016-08-15 00:02:31 UTC (rev 204458)
@@ -39,7 +39,7 @@
 - (void)_webProcessPlugInBrowserContextController:(WKWebProcessPlugInBrowserContextController *)controller willSendSubmitEventToForm:(WKWebProcessPlugInNodeHandle *)form inFrame:(WKWebProcessPlugInFrame *)sourceFrame targetFrame:(WKWebProcessPlugInFrame *)targetFrame values:(NSDictionary *)values;
 - (void)_webProcessPlugInBrowserContextController:(WKWebProcessPlugInBrowserContextController *)controller textDidChangeInTextField:(WKWebProcessPlugInNodeHandle *)textField inFrame:(WKWebProcessPlugInFrame *)frame initiatedByUserTyping:(BOOL)initiatedByUserTyping;
 
-// The return value is exposed in the UI process via the userObject parameter to -[id <_WKFormDelegate> _webView:willSubmitFormValues:userObject:submissionHandler:].
+// The return value is exposed in the UI process via the userObject parameter to -[id <_WKInputDelegate> _webView:willSubmitFormValues:userObject:submissionHandler:].
 - (NSObject <NSSecureCoding> *)_webProcessPlugInBrowserContextController:(WKWebProcessPlugInBrowserContextController *)controller willSubmitForm:(WKWebProcessPlugInNodeHandle *)form toFrame:(WKWebProcessPlugInFrame *)frame fromFrame:(WKWebProcessPlugInFrame *)sourceFrame withValues:(NSDictionary *)values;
 
 // The return value is exposed in the UI process via the userObject property of the _WKFormInputSession object.
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to