Title: [178679] trunk
Revision
178679
Author
timothy_hor...@apple.com
Date
2015-01-19 15:46:06 -0800 (Mon, 19 Jan 2015)

Log Message

Adjust naming of action menu SPI
https://bugs.webkit.org/show_bug.cgi?id=140644
<rdar://problem/19448129>

Reviewed by Brian Weinstein.

* platform/spi/mac/NSViewSPI.h:
Add an underscore.

* WebView/WebActionMenuController.mm:
(-[WebActionMenuController prepareForMenu:withEvent:]):
(-[WebActionMenuController willOpenMenu:withEvent:]):
(-[WebActionMenuController didCloseMenu:withEvent:]):
* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView prepareForMenu:withEvent:]):
(-[WebView willOpenMenu:withEvent:]):
(-[WebView didCloseMenu:withEvent:]):

* UIProcess/API/mac/WKView.mm:
(-[WKView initWithFrame:processPool:configuration:webView:]):
* UIProcess/mac/WKActionMenuController.mm:
(-[WKActionMenuController prepareForMenu:withEvent:]):
(-[WKActionMenuController willOpenMenu:withEvent:]):
(-[WKActionMenuController didCloseMenu:withEvent:]):
(-[WKActionMenuController menuNeedsUpdate:]):
(-[WKActionMenuController _updateActionMenuItems]):

* TestWebKitAPI/Tests/WebKit2ObjC/ActionMenus.mm:
(-[ActionMenusTestWKView runMenuSequenceAtPoint:preDidCloseMenuHandler:]):
(TestWebKitAPI::TEST):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (178678 => 178679)


--- trunk/Source/WebCore/ChangeLog	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebCore/ChangeLog	2015-01-19 23:46:06 UTC (rev 178679)
@@ -1,3 +1,14 @@
+2015-01-19  Timothy Horton  <timothy_hor...@apple.com>
+
+        Adjust naming of action menu SPI
+        https://bugs.webkit.org/show_bug.cgi?id=140644
+        <rdar://problem/19448129>
+
+        Reviewed by Brian Weinstein.
+
+        * platform/spi/mac/NSViewSPI.h:
+        Add an underscore.
+
 2015-01-19  Dhi Aurrahman  <diorah...@rockybars.com>
 
         Canonicalization of :lang() should preserve the :lang()'s arguments representations

Modified: trunk/Source/WebCore/platform/spi/mac/NSViewSPI.h (178678 => 178679)


--- trunk/Source/WebCore/platform/spi/mac/NSViewSPI.h	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebCore/platform/spi/mac/NSViewSPI.h	2015-01-19 23:46:06 UTC (rev 178679)
@@ -23,16 +23,10 @@
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#if USE(APPLE_INTERNAL_SDK) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101002
+// FIXME: This should include private headers when possible.
 
-#import <AppKit/NSView_Private.h>
-
-#else
-
 #import <AppKit/NSView.h>
 
 @interface NSView (Private)
-@property (strong) NSMenu *actionMenu;
+@property (strong) NSMenu *_actionMenu;
 @end
-
-#endif

Modified: trunk/Source/WebKit/mac/ChangeLog (178678 => 178679)


--- trunk/Source/WebKit/mac/ChangeLog	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebKit/mac/ChangeLog	2015-01-19 23:46:06 UTC (rev 178679)
@@ -1,3 +1,21 @@
+2015-01-19  Timothy Horton  <timothy_hor...@apple.com>
+
+        Adjust naming of action menu SPI
+        https://bugs.webkit.org/show_bug.cgi?id=140644
+        <rdar://problem/19448129>
+
+        Reviewed by Brian Weinstein.
+
+        * WebView/WebActionMenuController.mm:
+        (-[WebActionMenuController prepareForMenu:withEvent:]):
+        (-[WebActionMenuController willOpenMenu:withEvent:]):
+        (-[WebActionMenuController didCloseMenu:withEvent:]):
+        * WebView/WebView.mm:
+        (-[WebView _commonInitializationWithFrameName:groupName:]):
+        (-[WebView prepareForMenu:withEvent:]):
+        (-[WebView willOpenMenu:withEvent:]):
+        (-[WebView didCloseMenu:withEvent:]):
+
 2015-01-19  Beth Dakin  <bda...@apple.com>
 
         REGRESSION (r178290): Yellow highlight from context menu Lookup in Dictionary is 

Modified: trunk/Source/WebKit/mac/WebView/WebActionMenuController.mm (178678 => 178679)


--- trunk/Source/WebKit/mac/WebView/WebActionMenuController.mm	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebKit/mac/WebView/WebActionMenuController.mm	2015-01-19 23:46:06 UTC (rev 178679)
@@ -123,7 +123,7 @@
     if (!_webView)
         return;
 
-    NSMenu *actionMenu = _webView.actionMenu;
+    NSMenu *actionMenu = _webView._actionMenu;
     if (menu != actionMenu)
         return;
 
@@ -174,7 +174,7 @@
 
 - (void)willOpenMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != _webView.actionMenu)
+    if (menu != _webView._actionMenu)
         return;
 
     if (!menu.numberOfItems)
@@ -206,7 +206,7 @@
 
 - (void)didCloseMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != _webView.actionMenu)
+    if (menu != _webView._actionMenu)
         return;
 
     if (_currentActionContext && _hasActivatedActionContext) {

Modified: trunk/Source/WebKit/mac/WebView/WebView.mm (178678 => 178679)


--- trunk/Source/WebKit/mac/WebView/WebView.mm	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebKit/mac/WebView/WebView.mm	2015-01-19 23:46:06 UTC (rev 178679)
@@ -891,9 +891,9 @@
 #if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101000
     if ([self respondsToSelector:@selector(setActionMenu:)]) {
         RetainPtr<NSMenu> actionMenu = adoptNS([[NSMenu alloc] init]);
-        self.actionMenu = actionMenu.get();
+        self._actionMenu = actionMenu.get();
         _private->actionMenuController = [[WebActionMenuController alloc] initWithWebView:self];
-        self.actionMenu.autoenablesItems = NO;
+        self._actionMenu.autoenablesItems = NO;
     }
 
     if (Class gestureClass = NSClassFromString(@"NSImmediateActionGestureRecognizer")) {
@@ -8581,7 +8581,7 @@
 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101000
 - (void)prepareForMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != self.actionMenu)
+    if (menu != self._actionMenu)
         return;
 
     [_private->actionMenuController prepareForMenu:menu withEvent:event];
@@ -8589,7 +8589,7 @@
 
 - (void)willOpenMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != self.actionMenu)
+    if (menu != self._actionMenu)
         return;
 
     [_private->actionMenuController willOpenMenu:menu withEvent:event];
@@ -8597,7 +8597,7 @@
 
 - (void)didCloseMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != self.actionMenu)
+    if (menu != self._actionMenu)
         return;
 
     [_private->actionMenuController didCloseMenu:menu withEvent:event];

Modified: trunk/Source/WebKit2/ChangeLog (178678 => 178679)


--- trunk/Source/WebKit2/ChangeLog	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebKit2/ChangeLog	2015-01-19 23:46:06 UTC (rev 178679)
@@ -1,3 +1,20 @@
+2015-01-19  Timothy Horton  <timothy_hor...@apple.com>
+
+        Adjust naming of action menu SPI
+        https://bugs.webkit.org/show_bug.cgi?id=140644
+        <rdar://problem/19448129>
+
+        Reviewed by Brian Weinstein.
+
+        * UIProcess/API/mac/WKView.mm:
+        (-[WKView initWithFrame:processPool:configuration:webView:]):
+        * UIProcess/mac/WKActionMenuController.mm:
+        (-[WKActionMenuController prepareForMenu:withEvent:]):
+        (-[WKActionMenuController willOpenMenu:withEvent:]):
+        (-[WKActionMenuController didCloseMenu:withEvent:]):
+        (-[WKActionMenuController menuNeedsUpdate:]):
+        (-[WKActionMenuController _updateActionMenuItems]):
+
 2015-01-19  Zan Dobersek  <zdober...@igalia.com>
 
         [CoordinatedGraphics] Use C++ lambda instead of WTF::bind() in ThreadedCompositor::updateSceneState()

Modified: trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm (178678 => 178679)


--- trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm	2015-01-19 23:46:06 UTC (rev 178679)
@@ -3615,10 +3615,10 @@
 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101000
     if ([self respondsToSelector:@selector(setActionMenu:)]) {
         RetainPtr<NSMenu> menu = adoptNS([[NSMenu alloc] init]);
-        self.actionMenu = menu.get();
+        self._actionMenu = menu.get();
         _data->_actionMenuController = adoptNS([[WKActionMenuController alloc] initWithPage:*_data->_page view:self]);
-        self.actionMenu.delegate = _data->_actionMenuController.get();
-        self.actionMenu.autoenablesItems = NO;
+        self._actionMenu.delegate = _data->_actionMenuController.get();
+        self._actionMenu.autoenablesItems = NO;
     }
 
     if (Class gestureClass = NSClassFromString(@"NSImmediateActionGestureRecognizer")) {

Modified: trunk/Source/WebKit2/UIProcess/mac/WKActionMenuController.mm (178678 => 178679)


--- trunk/Source/WebKit2/UIProcess/mac/WKActionMenuController.mm	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Source/WebKit2/UIProcess/mac/WKActionMenuController.mm	2015-01-19 23:46:06 UTC (rev 178679)
@@ -96,7 +96,7 @@
 
 - (void)prepareForMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != _wkView.actionMenu)
+    if (menu != _wkView._actionMenu)
         return;
 
     [_wkView _dismissContentRelativeChildWindows];
@@ -114,7 +114,7 @@
 
 - (void)willOpenMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != _wkView.actionMenu)
+    if (menu != _wkView._actionMenu)
         return;
 
     if (!menu.numberOfItems)
@@ -147,7 +147,7 @@
 
 - (void)didCloseMenu:(NSMenu *)menu withEvent:(NSEvent *)event
 {
-    if (menu != _wkView.actionMenu)
+    if (menu != _wkView._actionMenu)
         return;
 
     [self _clearActionMenuState];
@@ -505,7 +505,7 @@
 
 - (void)menuNeedsUpdate:(NSMenu *)menu
 {
-    if (menu != _wkView.actionMenu)
+    if (menu != _wkView._actionMenu)
         return;
 
     ASSERT(_state != ActionMenuState::None);
@@ -749,7 +749,7 @@
 
 - (void)_updateActionMenuItems
 {
-    [_wkView.actionMenu removeAllItems];
+    [_wkView._actionMenu removeAllItems];
 
     NSArray *menuItems = [self _defaultMenuItems];
     RefPtr<WebHitTestResult> hitTestResult = [self _webHitTestResult];
@@ -760,10 +760,10 @@
         menuItems = [_wkView _actionMenuItemsForHitTestResult:toAPI(hitTestResult.get()) withType:_type defaultActionMenuItems:menuItems userData:toAPI(_userData.get())];
 
     for (NSMenuItem *item in menuItems)
-        [_wkView.actionMenu addItem:item];
+        [_wkView._actionMenu addItem:item];
 
-    if (!_wkView.actionMenu.numberOfItems)
-        [_wkView.actionMenu cancelTracking];
+    if (!_wkView._actionMenu.numberOfItems)
+        [_wkView._actionMenu cancelTracking];
 }
 
 @end

Modified: trunk/Tools/ChangeLog (178678 => 178679)


--- trunk/Tools/ChangeLog	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Tools/ChangeLog	2015-01-19 23:46:06 UTC (rev 178679)
@@ -1,3 +1,15 @@
+2015-01-19  Timothy Horton  <timothy_hor...@apple.com>
+
+        Adjust naming of action menu SPI
+        https://bugs.webkit.org/show_bug.cgi?id=140644
+        <rdar://problem/19448129>
+
+        Reviewed by Brian Weinstein.
+
+        * TestWebKitAPI/Tests/WebKit2ObjC/ActionMenus.mm:
+        (-[ActionMenusTestWKView runMenuSequenceAtPoint:preDidCloseMenuHandler:]):
+        (TestWebKitAPI::TEST):
+
 2015-01-19  Michael Catanzaro  <mcatanz...@igalia.com>
 
         [GTK] Generate the make dist manifest from a CMake template file

Modified: trunk/Tools/TestWebKitAPI/Tests/WebKit2ObjC/ActionMenus.mm (178678 => 178679)


--- trunk/Tools/TestWebKitAPI/Tests/WebKit2ObjC/ActionMenus.mm	2015-01-19 23:43:42 UTC (rev 178678)
+++ trunk/Tools/TestWebKitAPI/Tests/WebKit2ObjC/ActionMenus.mm	2015-01-19 23:46:06 UTC (rev 178679)
@@ -51,7 +51,7 @@
 - (void)willOpenMenu:(NSMenu *)menu withEvent:(NSEvent *)event;
 - (void)didCloseMenu:(NSMenu *)menu withEvent:(NSEvent *)event;
 
-- (NSMenu *)actionMenu;
+- (NSMenu *)_actionMenu;
 - (void)copy:(id)sender;
 
 @end
@@ -108,7 +108,7 @@
 {
     __block bool didFinishSequence = false;
 
-    NSMenu *actionMenu = self.actionMenu;
+    NSMenu *actionMenu = self._actionMenu;
     RetainPtr<NSEvent> event = [NSEvent mouseEventWithType:NSLeftMouseDown location:point modifierFlags:0 timestamp:0 windowNumber:self.window.windowNumber context:0 eventNumber:0 clickCount:0 pressure:0];
 
     dispatch_async(dispatch_get_main_queue(), ^{
@@ -480,7 +480,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::Word) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuReadOnlyText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"word", retrieveSelection([wkView pageRef]));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"word", watchPasteboardForString());
     }];
 
@@ -488,7 +488,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::Phrase) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuReadOnlyText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"New York", retrieveSelection([wkView pageRef]));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"New York", watchPasteboardForString());
     }];
 
@@ -518,7 +518,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::ContentEditableWords) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuEditableText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"editable", retrieveSelection([wkView pageRef]));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"editable", watchPasteboardForString());
     }];
 
@@ -526,7 +526,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::ContentEditablePhrase) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuEditableText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"New York", retrieveSelection([wkView pageRef]));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"New York", watchPasteboardForString());
     }];
 
@@ -536,7 +536,7 @@
         [[NSPasteboard generalPasteboard] clearContents];
         [[NSPasteboard generalPasteboard] setString:@"pasted string" forType:NSPasteboardTypeString];
         EXPECT_WK_STREQ(@"editable", retrieveSelection([wkView pageRef]));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagPaste);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagPaste);
 
         // Now check and see if our paste succeeded. It should only replace one 'editable'.
         watchEditableAreaForString([wkView pageRef], "editable1", "pasted string editable editable editable");
@@ -548,7 +548,7 @@
         [[NSPasteboard generalPasteboard] clearContents];
         [[NSPasteboard generalPasteboard] setString:@"pasted over phrase" forType:NSPasteboardTypeString];
         EXPECT_WK_STREQ(@"New York", retrieveSelection([wkView pageRef]));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagPaste);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagPaste);
 
         // Now check and see if our paste succeeded, and replaced the whole phrase.
         watchEditableAreaForString([wkView pageRef], "editable2", "pasted over phrase some words");
@@ -558,7 +558,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::TextInputWords) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuEditableText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"editable", retrieveSelectionInElement([wkView pageRef], "input1"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"editable", watchPasteboardForString());
     }];
 
@@ -566,7 +566,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::TextInputPhrase) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuEditableText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"New York", retrieveSelectionInElement([wkView pageRef], "input2"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"New York", watchPasteboardForString());
     }];
 
@@ -576,7 +576,7 @@
         [[NSPasteboard generalPasteboard] clearContents];
         [[NSPasteboard generalPasteboard] setString:@"pasted string" forType:NSPasteboardTypeString];
         EXPECT_WK_STREQ(@"editable", retrieveSelectionInElement([wkView pageRef], "input1"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagPaste);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagPaste);
 
         // Now check and see if our paste succeeded. It should only replace one 'editable'.
         watchEditableAreaForString([wkView pageRef], "input1", "pasted string editable editable editable");
@@ -588,7 +588,7 @@
         [[NSPasteboard generalPasteboard] clearContents];
         [[NSPasteboard generalPasteboard] setString:@"pasted over phrase" forType:NSPasteboardTypeString];
         EXPECT_WK_STREQ(@"New York", retrieveSelectionInElement([wkView pageRef], "input2"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagPaste);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagPaste);
 
         // Now check and see if our paste succeeded, and replaced the whole phrase.
         watchEditableAreaForString([wkView pageRef], "input2", "pasted over phrase some words");
@@ -598,7 +598,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::TextAreaWords) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuEditableText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"editable", retrieveSelectionInElement([wkView pageRef], "textarea1"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"editable", watchPasteboardForString());
     }];
 
@@ -606,7 +606,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::TextAreaPhrase) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuEditableText, [wkView _actionMenuResult].type);
         EXPECT_WK_STREQ(@"New York", retrieveSelectionInElement([wkView pageRef], "textarea2"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyText);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyText);
         EXPECT_WK_STREQ(@"New York", watchPasteboardForString());
     }];
 
@@ -616,7 +616,7 @@
         [[NSPasteboard generalPasteboard] clearContents];
         [[NSPasteboard generalPasteboard] setString:@"pasted" forType:NSPasteboardTypeString];
         EXPECT_WK_STREQ(@"editable", retrieveSelectionInElement([wkView pageRef], "textarea1"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagPaste);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagPaste);
 
         // Now check and see if our paste succeeded. It should only replace one 'editable'.
         watchEditableAreaForString([wkView pageRef], "textarea1", "pasted editable editable editable");
@@ -628,7 +628,7 @@
         [[NSPasteboard generalPasteboard] clearContents];
         [[NSPasteboard generalPasteboard] setString:@"pasted over phrase" forType:NSPasteboardTypeString];
         EXPECT_WK_STREQ(@"New York", retrieveSelectionInElement([wkView pageRef], "textarea2"));
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagPaste);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagPaste);
 
         // Now check and see if our paste succeeded, and replaced the whole phrase.
         watchEditableAreaForString([wkView pageRef], "textarea2", "pasted over phrase some words");
@@ -638,7 +638,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::Image) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuImage, [wkView _actionMenuResult].type);
 
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyImage);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyImage);
         NSImage *image = watchPasteboardForImage();
 
         EXPECT_EQ(215, image.size.width);
@@ -651,7 +651,7 @@
         EXPECT_EQ(kWKActionMenuImage, [wkView _actionMenuResult].type);
 
         didFinishDownload = false;
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 2, kWKContextActionItemTagSaveImageToDownloads);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 2, kWKContextActionItemTagSaveImageToDownloads);
         Util::run(&didFinishDownload);
     }];
     activeDownloadContext.shouldCheckForImage = false;
@@ -668,7 +668,7 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::Video) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuVideo, [wkView _actionMenuResult].type);
 
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyVideoURL);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyVideoURL);
         NSString *videoURL = watchPasteboardForString();
         EXPECT_WK_STREQ(@"test.mp4", [videoURL lastPathComponent]);
     }];
@@ -678,12 +678,12 @@
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::MSEVideo) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuVideo, [wkView _actionMenuResult].type);
 
-        performMenuItemAtIndexOfTypeAsync([wkView actionMenu], 0, kWKContextActionItemTagCopyVideoURL);
+        performMenuItemAtIndexOfTypeAsync([wkView _actionMenu], 0, kWKContextActionItemTagCopyVideoURL);
         NSString *videoURL = watchPasteboardForString();
         EXPECT_WK_STREQ(@"action-menu-targets.html", [videoURL lastPathComponent]);
 
         // Also, the download menu item should be disabled for non-downloadable video.
-        ensureMenuItemAtIndexOfTypeIsDisabled([wkView actionMenu], 2, kWKContextActionItemTagSaveVideoToDownloads);
+        ensureMenuItemAtIndexOfTypeIsDisabled([wkView _actionMenu], 2, kWKContextActionItemTagSaveVideoToDownloads);
     }];
 
     // HTTP link.
@@ -721,8 +721,8 @@
     RetainPtr<NSMenuItem> item = adoptNS([[NSMenuItem alloc] initWithTitle:@"Some Action" action:@selector(copy:) keyEquivalent:@""]);
     [wkView _setOverrideActionMenuItems:@[ item.get() ]];
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::Image) preDidCloseMenuHandler:^() {
-        EXPECT_EQ(1, [wkView actionMenu].numberOfItems);
-        EXPECT_WK_STREQ(@"Some Action", [[wkView actionMenu] itemAtIndex:0].title);
+        EXPECT_EQ(1, [wkView _actionMenu].numberOfItems);
+        EXPECT_WK_STREQ(@"Some Action", [[wkView _actionMenu] itemAtIndex:0].title);
     }];
     [wkView _setOverrideActionMenuItems:nil];
 
@@ -736,7 +736,7 @@
     // No menu should be built for whitespace (except in editable areas).
     [wkView runMenuSequenceAtPoint:windowPointForTarget(TargetType::PageWhitespace) preDidCloseMenuHandler:^() {
         EXPECT_EQ(kWKActionMenuNone, [wkView _actionMenuResult].type);
-        EXPECT_EQ(0, [wkView actionMenu].numberOfItems);
+        EXPECT_EQ(0, [wkView _actionMenu].numberOfItems);
     }];
 }
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to