ipad - 如何从 UITableViewCell 呈现 UIPopoverController?

标签 ipad uipopovercontroller

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    if (indexPath.row == 5)
    {
        [tableView deselectRowAtIndexPath:indexPath animated:YES];
        [enginesPopoverController presentPopoverFromRect:[tableView bounds] inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
    }
}

最佳答案

[popoverController presentPopoverFromRect:[tableView rectForRowAtIndexPath:indexPath] inView:[self view] permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];

祝你好运!

关于ipad - 如何从 UITableViewCell 呈现 UIPopoverController?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3352546/

相关文章:

ios - 在弹出框内滚动表格 View 会创建一个工件

ios - ios开发中如何消费wcf服务

适用于 iPad 的 iPhone 模拟器裁剪器?

iphone - UIDevice 模型与 localizedModel

ios - UIImagePickerController 在 iPad 模拟器上崩溃

ios - UIPopover 中的 UIWebView - 报告大小

javascript - Ipad - 我的 Webview/UIkit safari 浏览器无法运行 javascript

iphone - 将阴影应用于 UITextView.layer?

ios - 在 _strong id 类型的对象上找不到属性框架

uinavigationbar - iOS7GM UINavigationBar外观setBackgroundImage : forBarMetrics: not working in UIPopoverController