Rename -[WKNavigationAction destinationFrame] to -[WKNavigationAction targetFrame]
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 31 Mar 2014 23:49:47 +0000 (23:49 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 31 Mar 2014 23:49:47 +0000 (23:49 +0000)
https://bugs.webkit.org/show_bug.cgi?id=130994

Reviewed by Dan Bernstein.

* UIProcess/API/Cocoa/WKNavigationAction.h:
* UIProcess/API/Cocoa/WKNavigationAction.mm:
(-[WKNavigationAction description]):
(-[WKNavigationAction targetFrame]):
(-[WKNavigationAction setTargetFrame:]):
(-[WKNavigationAction destinationFrame]): Deleted.
(-[WKNavigationAction setDestinationFrame:]): Deleted.
* UIProcess/API/Cocoa/WKNavigationActionInternal.h:
* UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@166546 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/Cocoa/WKNavigationAction.h
Source/WebKit2/UIProcess/API/Cocoa/WKNavigationAction.mm
Source/WebKit2/UIProcess/API/Cocoa/WKNavigationActionInternal.h
Source/WebKit2/UIProcess/Cocoa/NavigationState.mm

index 8179680..b966a18 100644 (file)
@@ -1,3 +1,21 @@
+2014-03-31  Anders Carlsson  <andersca@apple.com>
+
+        Rename -[WKNavigationAction destinationFrame] to -[WKNavigationAction targetFrame]
+        https://bugs.webkit.org/show_bug.cgi?id=130994
+
+        Reviewed by Dan Bernstein.
+
+        * UIProcess/API/Cocoa/WKNavigationAction.h:
+        * UIProcess/API/Cocoa/WKNavigationAction.mm:
+        (-[WKNavigationAction description]):
+        (-[WKNavigationAction targetFrame]):
+        (-[WKNavigationAction setTargetFrame:]):
+        (-[WKNavigationAction destinationFrame]): Deleted.
+        (-[WKNavigationAction setDestinationFrame:]): Deleted.
+        * UIProcess/API/Cocoa/WKNavigationActionInternal.h:
+        * UIProcess/Cocoa/NavigationState.mm:
+        (WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
+
 2014-03-31  Tim Horton  <timothy_horton@apple.com>
 
         [iOS WebKit2] Flush all surfaces after painting into all of them, instead of after painting into each one
index 52f51f3..e6efec4 100644 (file)
@@ -43,7 +43,7 @@ WK_API_CLASS
 @interface WKNavigationAction : NSObject
 
 @property (nonatomic, readonly) WKFrameInfo *sourceFrame;
-@property (nonatomic, readonly) WKFrameInfo *destinationFrame;
+@property (nonatomic, readonly) WKFrameInfo *targetFrame;
 
 @property (nonatomic, readonly) WKNavigationType navigationType;
 @property (nonatomic, readonly) NSURLRequest *request;
index 8376184..c91de4f 100644 (file)
 
 @implementation WKNavigationAction {
     RetainPtr<WKFrameInfo> _sourceFrame;
-    RetainPtr<WKFrameInfo> _destinationFrame;
+    RetainPtr<WKFrameInfo> _targetFrame;
     RetainPtr<NSURLRequest> _request;
     RetainPtr<NSURL> _originalURL;
 }
 
 - (NSString *)description
 {
-    return [NSString stringWithFormat:@"<%@: %p; navigationType = %ld; request = %@; sourceFrame = %@; destinationFrame = %@>", NSStringFromClass(self.class), self,
-        (long)_navigationType, _request.get(), _sourceFrame.get(), _destinationFrame.get()];
+    return [NSString stringWithFormat:@"<%@: %p; navigationType = %ld; request = %@; sourceFrame = %@; targetFrame = %@>", NSStringFromClass(self.class), self,
+        (long)_navigationType, _request.get(), _sourceFrame.get(), _targetFrame.get()];
 }
 
 - (WKFrameInfo *)sourceFrame
     _sourceFrame = sourceFrame;
 }
 
-- (WKFrameInfo *)destinationFrame
+- (WKFrameInfo *)targetFrame
 {
-    return _destinationFrame.get();
+    return _targetFrame.get();
 }
 
-- (void)setDestinationFrame:(WKFrameInfo *)destinationFrame
+- (void)setTargetFrame:(WKFrameInfo *)targetFrame
 {
-    _destinationFrame = destinationFrame;
+    _targetFrame = targetFrame;
 }
 
 - (NSURLRequest *)request
index 39ab0e8..6c8b8b1 100644 (file)
@@ -30,7 +30,7 @@
 @interface WKNavigationAction ()
 
 @property (nonatomic, readwrite, strong) WKFrameInfo *sourceFrame;
-@property (nonatomic, readwrite, strong) WKFrameInfo *destinationFrame;
+@property (nonatomic, readwrite, strong) WKFrameInfo *targetFrame;
 
 @property (nonatomic, readwrite) WKNavigationType navigationType;
 @property (nonatomic, readwrite, copy) NSURLRequest *request;
index cc6f613..eacce89 100644 (file)
@@ -246,13 +246,13 @@ void NavigationState::PolicyClient::decidePolicyForNavigationAction(WebPageProxy
     auto navigationAction = adoptNS([[WKNavigationAction alloc] init]);
 
     if (destinationFrame)
-        [navigationAction setDestinationFrame:adoptNS([[WKFrameInfo alloc] initWithWebFrameProxy:*destinationFrame]).get()];
+        [navigationAction setTargetFrame:adoptNS([[WKFrameInfo alloc] initWithWebFrameProxy:*destinationFrame]).get()];
 
     if (sourceFrame) {
         if (sourceFrame == destinationFrame)
-            [navigationAction setSourceFrame:[navigationAction destinationFrame]];
+            [navigationAction setSourceFrame:[navigationAction targetFrame]];
         else
-            [navigationAction setDestinationFrame:adoptNS([[WKFrameInfo alloc] initWithWebFrameProxy:*sourceFrame]).get()];
+            [navigationAction setTargetFrame:adoptNS([[WKFrameInfo alloc] initWithWebFrameProxy:*sourceFrame]).get()];
     }
 
     [navigationAction setNavigationType:toWKNavigationType(navigationActionData.navigationType)];