mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-25 03:26:22 +08:00
feat: inapp fullscreen (#1330)
This commit is contained in:
committed by
GitHub
parent
4ae3bd2845
commit
5fd3d32200
@@ -15,7 +15,7 @@ Future<void> landScape() async {
|
||||
await document.documentElement?.requestFullscreen();
|
||||
} else if (Utils.isMobile) {
|
||||
await AutoOrientation.landscapeAutoMode(forceSensor: true);
|
||||
} else if (Utils.isDesktop) {
|
||||
} else if (Utils.isDesktop && Pref.nativeFullscreen) {
|
||||
await const MethodChannel(
|
||||
'com.alexmercerind/media_kit_video',
|
||||
).invokeMethod(
|
||||
@@ -94,17 +94,14 @@ Future<void> showStatusBar() async {
|
||||
mode,
|
||||
overlays: SystemUiOverlay.values,
|
||||
);
|
||||
} else if (Utils.isDesktop) {
|
||||
} else if (Utils.isDesktop && Pref.nativeFullscreen) {
|
||||
await const MethodChannel(
|
||||
'com.alexmercerind/media_kit_video',
|
||||
).invokeMethod(
|
||||
'Utils.ExitNativeFullscreen',
|
||||
);
|
||||
}
|
||||
} catch (exception, stacktrace) {
|
||||
if (kDebugMode) {
|
||||
debugPrint(exception.toString());
|
||||
debugPrint(stacktrace.toString());
|
||||
}
|
||||
} catch (_) {
|
||||
if (kDebugMode) rethrow;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user