정적 데이터를 표시하는 UIPopoverPresentationcontroller
을 표시하는 곳에서 viewControllerA가 있습니다. 자세한 내용은 아래 코드를 참조하십시오. 이 자동으로 기각 될 때 단순히보기에 만졌을 때 나는 "팝업"보기를 기각에 대한 코드를 작성하지 않은 것처럼닫을 때 UIPopoverPresentationController 이벤트 가져 오기
- (void)openPopupScreen:(id)sender {
PopupViewController *popupVC = [self.storyboard instantiateViewControllerWithIdentifier:@"popupViewController"];
popupVC.delegate = self;
popupVC.preferredContentSize = CGSizeMake(220.0f, 230.0f);
popupVC.modalPresentationStyle = UIModalPresentationPopover;
_popupView = popupVC.popoverPresentationController;
self.popupView.delegate = self;
self.popupView.sourceView = self.view;
self.popupView.backgroundColor = [UIColor whiteColor];
CGRect rect = CGRectMake(0.0f, 0.0f, 220.0f, 230.0f);
self.popupView.sourceRect = rect;
[self presentViewController:popupVC animated:YES completion:nil];
}
.
제 질문은 팝업이 해제되었을 때 이벤트가 필요하다는 것입니다.
미리 감사드립니다.
답변 해 주셔서 감사합니다. – Nikita