ipad设置uiview控制器

发布于 2024-09-17 10:17:54 字数 422 浏览 2 评论 0原文

我有这段代码

arrangeListViewController = [[[ArrangeListViewController alloc] init] autorelease];
arrangeList = [[UITableView alloc] initWithFrame:CGRectMake(attributesPadding, y, popoverWidth - 2* attributesPadding, popoverHeight - y - attributesPadding) style:UITableViewStylePlain];
arrangeList.layer.cornerRadius = 15;

,所以我将这个“arrangeList”添加到我的视图中,我可以看到它。但是我该如何为“arrangeList”分配视图控制器呢?

I have this code

arrangeListViewController = [[[ArrangeListViewController alloc] init] autorelease];
arrangeList = [[UITableView alloc] initWithFrame:CGRectMake(attributesPadding, y, popoverWidth - 2* attributesPadding, popoverHeight - y - attributesPadding) style:UITableViewStylePlain];
arrangeList.layer.cornerRadius = 15;

So i add this "arrangeList to my view and i can see it. But how do i go about assigning the view controller for "arrangeList'?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

青巷忧颜 2024-09-24 10:17:54

不太清楚你的意思,伙计...如果你想将表视图添加到 arrangeListViewController 中,那么请执行以下操作:

[arrangeListViewController.view addSubview:arrangeList];
[self.navigationController pushViewController:arrangeListViewController animated:YES];

Not too sure what you mean mate... if you want to add the table view to the arrangeListViewController then do this:

[arrangeListViewController.view addSubview:arrangeList];
[self.navigationController pushViewController:arrangeListViewController animated:YES];
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文