33 lines
756 B
Objective-C
33 lines
756 B
Objective-C
//
|
|
// AVNavigationController.m
|
|
// AVDemo
|
|
//
|
|
// Created on 12/17/25.
|
|
//
|
|
|
|
#import "AVNavigationController.h"
|
|
|
|
@implementation AVNavigationController
|
|
|
|
#pragma mark - 屏幕方向控制
|
|
|
|
/// 是否支持自动旋转
|
|
- (BOOL)shouldAutorotate {
|
|
// 转发给顶层视图控制器
|
|
return self.topViewController.shouldAutorotate;
|
|
}
|
|
|
|
/// 支持的屏幕方向
|
|
- (UIInterfaceOrientationMask)supportedInterfaceOrientations {
|
|
// 转发给顶层视图控制器
|
|
return self.topViewController.supportedInterfaceOrientations;
|
|
}
|
|
|
|
/// 优先的屏幕方向
|
|
- (UIInterfaceOrientation)preferredInterfaceOrientationForPresentation {
|
|
// 转发给顶层视图控制器
|
|
return self.topViewController.preferredInterfaceOrientationForPresentation;
|
|
}
|
|
|
|
@end
|