Merge pull request #548 from orz12/mod-imagepreview-hide-statusbar-in-android
mod: 图片预览页,安卓也隐藏状态栏
This commit is contained in:
@ -102,15 +102,12 @@ class _ImagePreviewState extends State<ImagePreview>
|
||||
);
|
||||
}
|
||||
|
||||
// 设置状态栏图标透明
|
||||
// 隐藏状态栏,避免遮挡图片内容
|
||||
setStatusBar() async {
|
||||
if (Platform.isIOS) {
|
||||
if (Platform.isIOS || Platform.isAndroid) {
|
||||
await StatusBarControl.setHidden(true,
|
||||
animation: StatusBarAnimation.SLIDE);
|
||||
}
|
||||
if (Platform.isAndroid) {
|
||||
await StatusBarControl.setColor(Colors.transparent);
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
|
Reference in New Issue
Block a user