iOS5 SDK と Phonegap 1.0.0 にアップグレード中のアプリがあります。
Childbrowser プラグインは正常に動作していますが、iTunes アプリ ストアへのリンクをクリックすると、リンクが Childbrowser ウィンドウで開かれます。
ChildBrowser プラグインを使用しない場合は、Appstore で直接開くことをお勧めします。
これはアプリストアのリンクです(アプリストア内のレビュー投稿ページへのリンクです)
これが AppDelegate の変更方法です
AppDelegate.m を下にスクロールして、以下を置き換えます。
- (BOOL)webView:(UIWebView *)theWebView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType
{
return [ super webView:theWebView shouldStartLoadWithRequest:request navigationType:navigationType ];
}
これとともに:
- (BOOL)webView:(UIWebView *)theWebView shouldStartLoadWithRequest:
(NSURLRequest *)request navigationType:
(UIWebViewNavigationType)navigationType
{
NSURL *url = [request URL];
if ([[url scheme] isEqualToString:@"gap"] || [url isFileURL]) {
return [ super webView:theWebView shouldStartLoadWithRequest:request
navigationType:navigationType ];
}
else {
ChildBrowserViewController* childBrowser =
[ [ ChildBrowserViewController alloc ] initWithScale:FALSE ];
[super.viewController presentModalViewController:childBrowser
animated:YES ];
[childBrowser loadURL:[url description]];
[childBrowser release];
return NO;
}
}
このブログ投稿で説明されている方法を使用して、Childbrowser を起動して実行しました http://iphonedevlog.wordpress.com/2011/09/24/installing-childbrowser-into-xcode-4-with-phonegap-1-0-mac -os-x-snow-leopard/
これを変更して目的のアクションを生成する方法について何か考えはありますか?
どうもありがとう..