mirror of
https://github.com/vodemn/m3_lightmeter.git
synced 2024-11-22 15:30:59 +00:00
revert
This commit is contained in:
parent
e554b2ef2e
commit
602e31f425
2 changed files with 5 additions and 30 deletions
|
@ -162,30 +162,6 @@ class AnimatedDialogState extends State<AnimatedDialog> with SingleTickerProvide
|
|||
}
|
||||
|
||||
void _openDialog() {
|
||||
final mediaQuery = MediaQuery.of(context);
|
||||
final closedSize = _key.currentContext!.size!;
|
||||
final sizeTween = SizeTween(
|
||||
begin: closedSize,
|
||||
end: widget.openedSize ??
|
||||
Size(
|
||||
mediaQuery.size.width - mediaQuery.padding.horizontal - Dimens.dialogMargin.horizontal,
|
||||
mediaQuery.size.height - mediaQuery.padding.vertical - Dimens.dialogMargin.vertical,
|
||||
),
|
||||
);
|
||||
final sizeAnimation = sizeTween.animate(_defaultCurvedAnimation);
|
||||
final renderBox = _key.currentContext!.findRenderObject()! as RenderBox;
|
||||
final closedOffset = renderBox.localToGlobal(Offset.zero);
|
||||
final offsetAnimation = SizeTween(
|
||||
begin: Size(
|
||||
closedOffset.dx + closedSize.width / 2,
|
||||
closedOffset.dy + closedSize.height / 2,
|
||||
),
|
||||
end: Size(
|
||||
mediaQuery.size.width / 2,
|
||||
mediaQuery.size.height / 2 + mediaQuery.padding.top / 2 - mediaQuery.padding.bottom / 2,
|
||||
),
|
||||
).animate(_defaultCurvedAnimation);
|
||||
|
||||
Navigator.of(context).push(
|
||||
PageRouteBuilder(
|
||||
barrierColor: Colors.transparent,
|
||||
|
@ -197,19 +173,19 @@ class AnimatedDialogState extends State<AnimatedDialog> with SingleTickerProvide
|
|||
child: _AnimatedOverlay(
|
||||
controller: _animationController,
|
||||
barrierColorAnimation: _barrierColorAnimation,
|
||||
sizeAnimation: sizeAnimation,
|
||||
offsetAnimation: offsetAnimation,
|
||||
sizeAnimation: _sizeAnimation,
|
||||
offsetAnimation: _offsetAnimation,
|
||||
borderRadiusAnimation: _borderRadiusAnimation,
|
||||
foregroundColorAnimation: _foregroundColorAnimation,
|
||||
elevationAnimation: _elevationAnimation,
|
||||
onDismiss: close,
|
||||
builder: widget.closedChild != null && widget.openedChild != null
|
||||
? (_) => _AnimatedSwitcher(
|
||||
sizeAnimation: sizeAnimation,
|
||||
sizeAnimation: _sizeAnimation,
|
||||
closedOpacityAnimation: _closedOpacityAnimation,
|
||||
openedOpacityAnimation: _openedOpacityAnimation,
|
||||
closedSize: sizeTween.begin!,
|
||||
openedSize: sizeTween.end!,
|
||||
closedSize: _sizeTween.begin!,
|
||||
openedSize: _sizeTween.end!,
|
||||
closedChild: widget.closedChild!,
|
||||
openedChild: widget.openedChild!,
|
||||
)
|
||||
|
|
|
@ -143,7 +143,6 @@ class MeteringContainerBuidler extends StatelessWidget {
|
|||
if (ev.isNaN || ev.isInfinite) {
|
||||
return List.empty();
|
||||
}
|
||||
return List.empty();
|
||||
|
||||
/// Depending on the `stopType` the exposure pairs list length is multiplied by 1,2 or 3
|
||||
final int evSteps = (ev * (stopType.index + 1)).round();
|
||||
|
|
Loading…
Reference in a new issue