forked from github/Toast-PhoneGap-Plugin
Merge pull request #112 from Capgemini-nantes-df/master
get real top most view controller
This commit is contained in:
commit
206b7e014e
@ -157,7 +157,7 @@ static id styling;
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (UIViewController*) getTopMostViewController {
|
- (UIViewController*) getTopMostViewController {
|
||||||
UIViewController *presentingViewController = [[[UIApplication sharedApplication] delegate] window].rootViewController;
|
UIViewController *presentingViewController = [[UIApplication sharedApplication] keyWindow].rootViewController;
|
||||||
while (presentingViewController.presentedViewController != nil) {
|
while (presentingViewController.presentedViewController != nil) {
|
||||||
presentingViewController = presentingViewController.presentedViewController;
|
presentingViewController = presentingViewController.presentedViewController;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user