fixed flashing app bar during hero in some cases
This commit is contained in:
parent
3c90ef312a
commit
56b865af13
1 changed files with 21 additions and 17 deletions
|
@ -2,6 +2,7 @@ import 'package:aves/model/settings/settings.dart';
|
|||
import 'package:aves/theme/durations.dart';
|
||||
import 'package:aves/widgets/aves_app.dart';
|
||||
import 'package:aves/widgets/common/fx/blurred.dart';
|
||||
import 'package:aves/widgets/common/providers/query_provider.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
|
@ -100,7 +101,9 @@ class AvesAppBar extends StatelessWidget {
|
|||
final pushing = direction == HeroFlightDirection.push;
|
||||
Widget popBuilder(context, child) => Opacity(opacity: 1 - animation.value, child: child);
|
||||
Widget pushBuilder(context, child) => Opacity(opacity: animation.value, child: child);
|
||||
return Material(
|
||||
return QueryProvider(
|
||||
initialQuery: null,
|
||||
child: Material(
|
||||
type: MaterialType.transparency,
|
||||
child: DefaultTextStyle(
|
||||
style: DefaultTextStyle.of(toHero).style,
|
||||
|
@ -119,6 +122,7 @@ class AvesAppBar extends StatelessWidget {
|
|||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue