我在我的UIPopover增加了一个 but子。 主计长看来没有回答问题。 我不知道我是否应该把一些财产交给UIPopoverController,或者什么。 这里的法典使登革观点和纽州成为可能。
- (void)topicImageButtonPressed
{
CGRect aFrame = CGRectMake(0.0, 0.0, 1000.0, 600.0);
UIViewController *aView = [[UIViewController alloc] init];
aView.view.frame = aFrame;
UIImageView *iView = [[UIImageView alloc] init];
[iView setContentMode:UIViewContentModeScaleAspectFit];
[iView setImage:self.topicImageView1.image];
aView.view = iView;
UIButton *nextButton = [UIButton buttonWithType:UIButtonTypeRoundedRect];
[nextButton addTarget:self
action:@selector(quizButtonPressed:)
forControlEvents:UIControlEventTouchUpInside];
[nextButton setTitle:@"Next" forState:UIControlStateNormal];
nextButton.frame = CGRectMake(700.0, 550.0, 160.0, 40.0);
[aView.view addSubview:nextButton];
//aView.view.backgroundColor = [UIColor colorWithPatternImage:self.topicImageView1.image];
imagePopoverController = [[UIPopoverController alloc]
initWithContentViewController:aView];
imagePopoverController.popoverContentSize = CGSizeMake(1000, 600);
imagePopoverController.passthroughViews = [NSArray arrayWithObject:nextButton];
[imagePopoverController presentPopoverFromRect:CGRectMake(212, 10, 1000, 600) inView:self.view
permittedArrowDirections:0 animated:YES];
}