半屏聊天的完善
This commit is contained in:
@@ -24,6 +24,24 @@
|
||||
if ([rootViewController isKindOfClass:NSClassFromString(@"MMDrawerController")]) {
|
||||
rootViewController = (UIViewController *)[rootViewController valueForKey:@"centerViewController"];
|
||||
}
|
||||
|
||||
///兼容房间内私聊的
|
||||
UIWindow * currentWindow;
|
||||
for (int i = 0; i < [UIApplication sharedApplication].windows.count; i++) {
|
||||
UIWindow * window = [[UIApplication sharedApplication].windows objectAtIndex:i];
|
||||
if(window.tag == 1001) {
|
||||
currentWindow = window;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (currentWindow) {
|
||||
[currentWindow.rootViewController.navigationController popViewControllerAnimated:YES];
|
||||
[currentWindow.superview removeFromSuperview];
|
||||
currentWindow.rootViewController = nil;
|
||||
currentWindow.windowLevel = -1;
|
||||
currentWindow = nil;
|
||||
}
|
||||
|
||||
UIViewController *currentVC = [self getCurrentVCFrom:rootViewController];
|
||||
return currentVC;
|
||||
}
|
||||
|
Reference in New Issue
Block a user