0
私はiPadのポップオーバーでピッカービューを表示しようとしていますが、ポップオーバーが空であるiOSの空のポップオーバー
case timezoneSetting: {
UIViewController *pickerViewController = (setting.type == timeSetting) ?
[[[TimePickerViewController alloc] initWithSetting:setting] autorelease] :
[[[TimeZonePickerViewController alloc] initWithSetting:setting] autorelease];
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) {
CGRect frame = [self.tableView rectForRowAtIndexPath:indexPath];
CGRect cellRect = CGRectMake(frame.origin.x, frame.origin.y - tableView.contentOffset.y, frame.size.width, frame.size.height);
[pickerPopover setContentViewController:[[[UINavigationController alloc] initWithRootViewController:pickerViewController] autorelease]];
[pickerPopover presentPopoverFromRect:cellRect inView:self.view permittedArrowDirections:(UIPopoverArrowDirectionRight | UIPopoverArrowDirectionUp) animated:YES];
}
else {
[self.navigationController pushViewController:pickerViewController animated:YES];
}
break;
}
を呼び出すことが必要なものでしたあなたのポップオーバービューに 'UIPickerView'を作成して追加します。 –
これは私が紛失していることです。これはレガシーコードであり、私はinitwithRootViewController:pickerViewControllerがそれを処理すると考えていましたか?だから私はないと思いますか? –
かもしれません。あなたがTimePickerViewController' 'の実装をチェックし、そこにある –