【发布时间】:2011-02-15 07:06:21
【问题描述】:
我根据以下教程 Multiple Virtual Pages in a Scrollview 创建了一个应用程序。 我添加了一个按钮,按下时会显示 UIActionSheet。它在第一页上效果很好,但不显示该表的其他页面。我认为这是因为工作表显示在(0,0),所以我尝试使用视图框架初始化工作表。没有运气。
UIActionSheet *actionSheet = [[UIActionSheet alloc] initWithFrame:self.view.frame];
[actionSheet setTitle:NSLocalizedString(@"Create Event", @"Create Event")];
[actionSheet setDelegate:self];
[actionSheet addButtonWithTitle:NSLocalizedString(@"Cancel", @"Cancel")];
[actionSheet addButtonWithTitle:NSLocalizedString(@"Save", @"Save")];
[actionSheet addButtonWithTitle:NSLocalizedString(@"Discard", @"Discard")];
[actionSheet setDestructiveButtonIndex:2];[actionSheet showInView:self.view];
[actionSheet release];
有人知道这里发生了什么吗?我能做些什么来纠正这个问题?
【问题讨论】:
标签: iphone uiviewcontroller uiscrollview uiactionsheet