fix: desktop window appbar (#450)

This commit is contained in:
Noo6
2024-07-05 12:42:38 +08:00
committed by GitHub
parent 43cebd0c04
commit 4b3c4870ba

View File

@@ -14,6 +14,8 @@ final class _AppBar extends CustomAppBar {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
if (isDesktop) return super.build(context);
final placeholder = SizedBox( final placeholder = SizedBox(
height: CustomAppBar.barHeight ?? 0 + MediaQuery.of(context).padding.top, height: CustomAppBar.barHeight ?? 0 + MediaQuery.of(context).padding.top,
); );
@@ -25,7 +27,7 @@ final class _AppBar extends CustomAppBar {
return ValBuilder( return ValBuilder(
listenable: selectIndex, listenable: selectIndex,
builder: (idx) { builder: (idx) {
if (idx == AppTab.ssh.index && !isWindows && !isLinux) { if (idx == AppTab.ssh.index) {
return placeholder; return placeholder;
} }
return super.build(context); return super.build(context);