【发布时间】:2012-07-05 17:13:16
【问题描述】:
So I'm creating an iPad app that displays images in a UITableView and when when a row/image is selected it pushes another view controller that plays a video in full screen.这一切正常,但我想动画从表格中图像的原始大小到全屏视频的过渡。此处的此视频在 http://www.apple.com/ipad/videos/#itunes 中大约 1 秒显示我想要的内容。那么我将如何获得所选单元格的框架?以及如何将视图从单元格框架转换为全屏?
这是我现在的过渡方式:
- (void) tableView: (UITableView *) tableView didSelectRowAtIndexPath: (NSIndexPath *) indexPath
{
if (indexPath.row == 0)
{
VideoViewController * video1 = [[VideoViewController alloc] init];
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:video1];
navController.modalTransitionStyle = UIModalTransitionStyleCrossDissolve;
navController.modalPresentationStyle = UIModalPresentationFullScreen;
navController.navigationBarHidden = YES;
[self presentModalViewController:navController animated:YES];
}
}
【问题讨论】:
标签: ios uitableview modalviewcontroller uimodaltransitionstyle