mirror of
https://github.com/KRTirtho/spotube.git
synced 2025-09-12 23:45:18 +00:00
android appWindow related bug in Home fix
This commit is contained in:
parent
f6969d678a
commit
8dea8dc051
@ -162,32 +162,33 @@ class Home extends HookConsumerWidget {
|
|||||||
};
|
};
|
||||||
}, [localStorage]);
|
}, [localStorage]);
|
||||||
|
|
||||||
|
final titleBarContents = Row(
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Container(
|
||||||
|
constraints: BoxConstraints(
|
||||||
|
maxWidth: titleBarDragMaxWidth.toDouble(),
|
||||||
|
),
|
||||||
|
color: Theme.of(context).navigationRailTheme.backgroundColor,
|
||||||
|
child: MoveWindow(),
|
||||||
|
),
|
||||||
|
Expanded(child: MoveWindow()),
|
||||||
|
if (!Platform.isMacOS && !Platform.isAndroid && !Platform.isIOS)
|
||||||
|
const TitleBarActionButtons(),
|
||||||
|
],
|
||||||
|
))
|
||||||
|
],
|
||||||
|
);
|
||||||
|
|
||||||
return SafeArea(
|
return SafeArea(
|
||||||
child: Scaffold(
|
child: Scaffold(
|
||||||
body: Column(
|
body: Column(
|
||||||
children: [
|
children: [
|
||||||
WindowTitleBarBox(
|
Platform.isAndroid || Platform.isIOS
|
||||||
child: Row(
|
? titleBarContents
|
||||||
children: [
|
: WindowTitleBarBox(child: titleBarContents),
|
||||||
Expanded(
|
|
||||||
child: Row(
|
|
||||||
children: [
|
|
||||||
Container(
|
|
||||||
constraints: BoxConstraints(
|
|
||||||
maxWidth: titleBarDragMaxWidth.toDouble(),
|
|
||||||
),
|
|
||||||
color: Theme.of(context)
|
|
||||||
.navigationRailTheme
|
|
||||||
.backgroundColor,
|
|
||||||
child: MoveWindow(),
|
|
||||||
),
|
|
||||||
Expanded(child: MoveWindow()),
|
|
||||||
if (!Platform.isMacOS) const TitleBarActionButtons(),
|
|
||||||
],
|
|
||||||
))
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Row(
|
child: Row(
|
||||||
children: [
|
children: [
|
||||||
|
@ -2,9 +2,7 @@ import 'package:flutter/material.dart';
|
|||||||
import 'package:go_router/go_router.dart';
|
import 'package:go_router/go_router.dart';
|
||||||
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||||||
import 'package:spotify/spotify.dart';
|
import 'package:spotify/spotify.dart';
|
||||||
import 'package:spotube/components/Playlist/PlaylistView.dart';
|
|
||||||
import 'package:spotube/components/Shared/PlaybuttonCard.dart';
|
import 'package:spotube/components/Shared/PlaybuttonCard.dart';
|
||||||
import 'package:spotube/components/Shared/SpotubePageRoute.dart';
|
|
||||||
import 'package:spotube/helpers/image-to-url-string.dart';
|
import 'package:spotube/helpers/image-to-url-string.dart';
|
||||||
import 'package:spotube/hooks/useBreakpointValue.dart';
|
import 'package:spotube/hooks/useBreakpointValue.dart';
|
||||||
import 'package:spotube/provider/Playback.dart';
|
import 'package:spotube/provider/Playback.dart';
|
||||||
|
@ -79,16 +79,16 @@ BreakpointUtils useBreakpoints() {
|
|||||||
width <= 1920 &&
|
width <= 1920 &&
|
||||||
breakpoint.value != Breakpoints.xl) {
|
breakpoint.value != Breakpoints.xl) {
|
||||||
breakpoint.value = Breakpoints.xl;
|
breakpoint.value = Breakpoints.xl;
|
||||||
} else if (width > 768 &&
|
} else if (width > 800 &&
|
||||||
width <= 1366 &&
|
width <= 1366 &&
|
||||||
breakpoint.value != Breakpoints.lg) {
|
breakpoint.value != Breakpoints.lg) {
|
||||||
breakpoint.value = Breakpoints.lg;
|
breakpoint.value = Breakpoints.lg;
|
||||||
} else if (width > 360 &&
|
} else if (width > 414 &&
|
||||||
width <= 768 &&
|
width <= 800 &&
|
||||||
breakpoint.value != Breakpoints.md) {
|
breakpoint.value != Breakpoints.md) {
|
||||||
breakpoint.value = Breakpoints.md;
|
breakpoint.value = Breakpoints.md;
|
||||||
} else if (width >= 250 &&
|
} else if (width >= 250 &&
|
||||||
width <= 360 &&
|
width <= 414 &&
|
||||||
breakpoint.value != Breakpoints.sm) {
|
breakpoint.value != Breakpoints.sm) {
|
||||||
breakpoint.value = Breakpoints.sm;
|
breakpoint.value = Breakpoints.sm;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user