I want to develop an iOS native app using WKWebView. when I loading a page e.g: http://www.google.com and When I long press "Google" logo, it will popup a UIAlertViewController with "Save Image" "Copy" "Cancel" items.
but when I tap on "Save Image" the photo will be saved into system "photo library" what I need is to "Save Image" to my app documents folder.
is there a way to implement it?
menu appear when you long press on WKWebview is UIMenuController . You can customise it to add new items to it - new buttons with you custom action on it. But you cant Modify existing menu action.
If you want to copy image to some other place with menu, Add new menu to save image to to document folder.
UIMenuItem *menuItem = [[UIMenuItem alloc] initWithTitle:@"Copy Image"
action:@selector(customAction:)];
[[UIMenuController sharedMenuController] setMenuItems:[NSArray arrayWithObject:menuItem]];