mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-20 03:06:59 +08:00
mod: 竖屏改为只持续两秒
This commit is contained in:
@@ -25,6 +25,16 @@ Future<void> landScape() async {
|
||||
}
|
||||
}
|
||||
|
||||
//竖屏
|
||||
Future<void> verticalScreenForTwoSeconds() async {
|
||||
await SystemChrome.setPreferredOrientations([
|
||||
DeviceOrientation.portraitUp,
|
||||
]);
|
||||
Future.delayed(const Duration(seconds: 2), () {
|
||||
autoScreen();
|
||||
});
|
||||
}
|
||||
|
||||
//竖屏
|
||||
Future<void> verticalScreen() async {
|
||||
await SystemChrome.setPreferredOrientations([
|
||||
|
||||
Reference in New Issue
Block a user