2011-04-27 2 views

답변

1

NSView를 통해 NSNotification을 게시하고 UIViewController를 옵저버로 추가하십시오.

+0

가장 쉬운 방법이라고 생각하십시오. – madmax

1

NSNotification이 잘 작동합니다 게시에 대한

... 당신은 또한 당신의있는 UITableViewController 클래스의 콜백 객체와 선택기를 만들 수 있습니다.

당신이 당신의있는 tableView의 건물 인 didSelectRowAtIndexPath에서 다음

에 값을 저장 ... 콜백 객체와 콜백 선택

initWithTarget:(id)theTarget andSelector:(SEL) theSelector 

로있는 UITableViewController를 초기화 할 수

는 ... 전화

[self.target performSelector:self.selector]; 

이 방법론을 사용하면 원하는대로 콜백 메서드를 정의 할 수 있습니다 .. Popover를 만든 ViewController 클래스에서, 당신은 이렇게 할 수 있습니다 ...

[[MyTableView alloc] initWithTarget:(self) andSelector:@selector(popoverControllerDidRequestClose)]; 
관련 문제