orientation change test
This commit is contained in:
1 parent
a5b1cd6c99
commit
06aa772a02
3 files changed
+10
-3
No files matched your search
@@ -56,6 +56,11 @@
|
|||||||
</array>
|
</array>
|
||||||
<key>NSLocalNetworkUsageDescription</key>
|
<key>NSLocalNetworkUsageDescription</key>
|
||||||
<string>Moonlight uses the local network to connect to your gaming PC for streaming.</string>
|
<string>Moonlight uses the local network to connect to your gaming PC for streaming.</string>
|
||||||
|
<key>UIApplicationSceneManifest</key>
|
||||||
|
<dict>
|
||||||
|
<key>UIApplicationSupportsMultipleScenes</key>
|
||||||
|
<false/>
|
||||||
|
</dict>
|
||||||
<key>UIApplicationSupportsIndirectInputEvents</key>
|
<key>UIApplicationSupportsIndirectInputEvents</key>
|
||||||
<true/>
|
<true/>
|
||||||
<key>UILaunchStoryboardName</key>
|
<key>UILaunchStoryboardName</key>
|
||||||
@@ -69,7 +74,7 @@
|
|||||||
<string>armv7</string>
|
<string>armv7</string>
|
||||||
</array>
|
</array>
|
||||||
<key>UIRequiresFullScreen</key>
|
<key>UIRequiresFullScreen</key>
|
||||||
<false/>
|
<true/>
|
||||||
<key>UIStatusBarHidden</key>
|
<key>UIStatusBarHidden</key>
|
||||||
<true/>
|
<true/>
|
||||||
<key>UISupportedInterfaceOrientations</key>
|
<key>UISupportedInterfaceOrientations</key>
|
||||||
|
|||||||
@@ -10,8 +10,8 @@ import Foundation
|
|||||||
|
|
||||||
import UIKit
|
import UIKit
|
||||||
|
|
||||||
class OrientationHelper {
|
@objc class OrientationHelper: NSObject {
|
||||||
static func updateOrientationToLandscape() {
|
@objc static func updateOrientationToLandscape() {
|
||||||
if #available(iOS 16.0, *) {
|
if #available(iOS 16.0, *) {
|
||||||
// 调用此方法会使视图控制器重新评估其支持的方向集。
|
// 调用此方法会使视图控制器重新评估其支持的方向集。
|
||||||
UIApplication.shared.keyWindow?.rootViewController?.setNeedsUpdateOfSupportedInterfaceOrientations()
|
UIApplication.shared.keyWindow?.rootViewController?.setNeedsUpdateOfSupportedInterfaceOrientations()
|
||||||
|
|||||||
@@ -29,6 +29,7 @@
|
|||||||
#import "LocalizationHelper.h"
|
#import "LocalizationHelper.h"
|
||||||
#import "CustomEdgeSwipeGestureRecognizer.h"
|
#import "CustomEdgeSwipeGestureRecognizer.h"
|
||||||
#import "DataManager.h"
|
#import "DataManager.h"
|
||||||
|
#import "Moonlight-Swift.h"
|
||||||
|
|
||||||
#if !TARGET_OS_TV
|
#if !TARGET_OS_TV
|
||||||
#import "SettingsViewController.h"
|
#import "SettingsViewController.h"
|
||||||
@@ -1003,6 +1004,7 @@ static NSMutableSet* hostList;
|
|||||||
|
|
||||||
- (void)viewDidLoad
|
- (void)viewDidLoad
|
||||||
{
|
{
|
||||||
|
[OrientationHelper updateOrientationToLandscape];
|
||||||
[super viewDidLoad];
|
[super viewDidLoad];
|
||||||
[self attachWaterMark];
|
[self attachWaterMark];
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user