ente/lib/ui/viewer/file/custom_app_bar.dart
2022-08-29 20:13:31 +05:30

23 lines
485 B
Dart

import 'package:flutter/material.dart';
class CustomAppBar extends PreferredSize {
@override
final Widget child;
final double height;
const CustomAppBar(this.child, {Key key, this.height = kToolbarHeight})
: super(key: key);
@override
Size get preferredSize => Size.fromHeight(height);
@override
Widget build(BuildContext context) {
return Container(
height: preferredSize.height,
alignment: Alignment.center,
child: child,
);
}
}