Skip to content

Commit a1abb7b

Browse files
authored
fix: attempt to fix flicker on some setups (#1344)
1 parent ce2e5af commit a1abb7b

File tree

1 file changed

+14
-31
lines changed

1 file changed

+14
-31
lines changed

lib/app/view/desktop_home_page.dart

Lines changed: 14 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -100,40 +100,23 @@ class _DesktopHomePageState extends State<DesktopHomePage> {
100100
},
101101
);
102102

103-
return Stack(
104-
alignment: Alignment.center,
105-
children: [
106-
ExcludeFocus(
107-
excluding: isInFullWindowMode == true,
108-
child: Row(
109-
children: [
110-
Expanded(
111-
child: Column(
112-
children: [
113-
const Expanded(child: MasterDetailPage()),
114-
if (!playerToTheRight)
115-
const PlayerView(position: PlayerPosition.bottom),
116-
],
117-
),
118-
),
119-
if (playerToTheRight)
120-
AnimatedOpacity(
121-
opacity: playerToTheRight ? 1 : 0,
122-
duration: const Duration(milliseconds: 300),
123-
child: const SizedBox(
103+
return Scaffold(
104+
backgroundColor: isVideo ? Colors.black : null,
105+
body: isInFullWindowMode
106+
? const PlayerView(position: PlayerPosition.fullWindow)
107+
: Row(
108+
children: [
109+
const Expanded(child: const MasterDetailPage()),
110+
if (playerToTheRight)
111+
const SizedBox(
124112
width: kSideBarPlayerWidth,
125113
child: PlayerView(position: PlayerPosition.sideBar),
126114
),
127-
),
128-
],
129-
),
130-
),
131-
if (isInFullWindowMode == true)
132-
Scaffold(
133-
backgroundColor: isVideo ? Colors.black : null,
134-
body: const PlayerView(position: PlayerPosition.fullWindow),
135-
),
136-
],
115+
],
116+
),
117+
bottomNavigationBar: !playerToTheRight && !isInFullWindowMode
118+
? const PlayerView(position: PlayerPosition.bottom)
119+
: null,
137120
);
138121
}
139122
}

0 commit comments

Comments
 (0)