fixed searching from drawer on mobile
This commit is contained in:
parent
fe8415fced
commit
426264d186
3 changed files with 9 additions and 4 deletions
|
@ -15,6 +15,11 @@ All notable changes to this project will be documented in this file.
|
||||||
- Slideshow: keep playing when losing focus but app is still visible (e.g. split screen)
|
- Slideshow: keep playing when losing focus but app is still visible (e.g. split screen)
|
||||||
- upgraded Flutter to stable v3.16.7
|
- upgraded Flutter to stable v3.16.7
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- crash when loading some large DNG in viewer
|
||||||
|
- searching from drawer on mobile
|
||||||
|
|
||||||
## <a id="v1.10.2"></a>[v1.10.2] - 2023-12-24
|
## <a id="v1.10.2"></a>[v1.10.2] - 2023-12-24
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
|
@ -50,7 +50,7 @@ class PageNavTile extends StatelessWidget {
|
||||||
: null,
|
: null,
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.maybeOf(context)?.pop();
|
Navigator.maybeOf(context)?.pop();
|
||||||
final route = routeBuilder(context, routeName);
|
final route = routeBuilder(context, routeName, topLevel);
|
||||||
if (topLevel) {
|
if (topLevel) {
|
||||||
Navigator.maybeOf(context)?.pushAndRemoveUntil(
|
Navigator.maybeOf(context)?.pushAndRemoveUntil(
|
||||||
route,
|
route,
|
||||||
|
@ -65,7 +65,7 @@ class PageNavTile extends StatelessWidget {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
static Route routeBuilder(BuildContext context, String routeName) {
|
static Route routeBuilder(BuildContext context, String routeName, bool topLevel) {
|
||||||
switch (routeName) {
|
switch (routeName) {
|
||||||
case SearchPage.routeName:
|
case SearchPage.routeName:
|
||||||
final currentCollection = context.read<CollectionLens?>();
|
final currentCollection = context.read<CollectionLens?>();
|
||||||
|
@ -74,7 +74,7 @@ class PageNavTile extends StatelessWidget {
|
||||||
searchFieldLabel: context.l10n.searchCollectionFieldHint,
|
searchFieldLabel: context.l10n.searchCollectionFieldHint,
|
||||||
searchFieldStyle: Themes.searchFieldStyle(context),
|
searchFieldStyle: Themes.searchFieldStyle(context),
|
||||||
source: context.read<CollectionSource>(),
|
source: context.read<CollectionSource>(),
|
||||||
parentCollection: currentCollection?.copyWith(),
|
parentCollection: topLevel ? currentCollection?.copyWith() : currentCollection,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -253,7 +253,7 @@ class _TvRailState extends State<TvRail> {
|
||||||
|
|
||||||
void _goTo(String routeName) {
|
void _goTo(String routeName) {
|
||||||
Navigator.maybeOf(context)?.pushAndRemoveUntil(
|
Navigator.maybeOf(context)?.pushAndRemoveUntil(
|
||||||
PageNavTile.routeBuilder(context, routeName),
|
PageNavTile.routeBuilder(context, routeName, true),
|
||||||
(route) => false,
|
(route) => false,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue