This is my code :
body: SafeArea(
child: Stack(
//fit: StackFit.expand,
children: [
Positioned(
top: AppBar().preferredSize.height,
child: Offstage(
offstage: !bShowUnityBG,
child: UnityWidget(
onUnityCreated: onUnityCreated,
onUnityMessage: onUnityMessage,
onUnitySceneLoaded: onUnitySceneLoaded,
//fullscreen: false,
),
),
),
I want to use
top: AppBar().preferredSize.height,
to show the status bar and let UnityWidget be the background.
But I can't adjust the height of Wiget and keep top distance.
This is my code : body: SafeArea( child: Stack( //fit: StackFit.expand, children: [ Positioned( top: AppBar().preferredSize.height, child: Offstage( offstage: !bShowUnityBG, child: UnityWidget( onUnityCreated: onUnityCreated, onUnityMessage: onUnityMessage, onUnitySceneLoaded: onUnitySceneLoaded, //fullscreen: false, ), ), ), I want to use top: AppBar().preferredSize.height, to show the status bar and let UnityWidget be the background. But I can't adjust the height of Wiget and keep top distance.