Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-08-30 14:50:54 +08:00
parent 80fa0240e9
commit 8d94c0405f
115 changed files with 3150 additions and 1438 deletions

View File

@@ -113,18 +113,14 @@ class _DynamicSliverAppBarMediumState extends State<DynamicSliverAppBarMedium> {
});
}
Orientation? _orientation;
late Size size;
double? _width;
@override
void didChangeDependencies() {
super.didChangeDependencies();
size = MediaQuery.sizeOf(context);
final orientation = size.width > size.height
? Orientation.landscape
: Orientation.portrait;
if (orientation != _orientation) {
_orientation = orientation;
final width = MediaQuery.widthOf(context);
if (_width != width) {
_width = width;
_height = 0;
_updateHeight();
}
@@ -139,7 +135,7 @@ class _DynamicSliverAppBarMediumState extends State<DynamicSliverAppBarMedium> {
alignment: Alignment.topLeft,
child: SizedBox(
key: _childKey,
width: size.width,
width: _width,
child: widget.flexibleSpace,
),
),