我想将我的应用程序中的网页转换为 Safari 阅读器模式。这是真的吗?
问问题
540 次
1 回答
1
你是这个意思?
#import <SafariServices/SafariServices.h>
NSString *sURL = @"http://google.com";
NSURL *URL = [NSURL URLWithString:sURL];
SFSafariViewController *safari = [[SFSafariViewController alloc] initWithURL:URL]; // 1.
//SFSafariViewController *safari = [[SFSafariViewController alloc] initWithURL:URL entersReaderIfAvailable:YES]; // 2.
[self presentViewController:safari animated:YES completion:nil];
于 2016-03-18T04:14:00.467 回答