mirror of
https://github.com/revanced/revanced-manager.git
synced 2025-06-12 12:47:37 +02:00
refactor: migrate MediaQuery properties to InheritedModel (#1115)
Co-authored-by: Ushie <ushiekane@gmail.com>
This commit is contained in:
@ -7,7 +7,7 @@ class AppSkeletonLoader extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final screenWidth = MediaQuery.of(context).size.width;
|
||||
final screenWidth = MediaQuery.sizeOf(context).width;
|
||||
return ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: 7,
|
||||
|
@ -25,7 +25,7 @@ class _GradientProgressIndicatorState extends State<GradientProgressIndicator> {
|
||||
),
|
||||
),
|
||||
height: 5,
|
||||
width: MediaQuery.of(context).size.width * widget.progress!,
|
||||
width: MediaQuery.sizeOf(context).width * widget.progress!,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
@ -8,8 +8,9 @@ class OptionsTextField extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final sHeight = MediaQuery.of(context).size.height;
|
||||
final sWidth = MediaQuery.of(context).size.width;
|
||||
final size = MediaQuery.sizeOf(context);
|
||||
final sHeight = size.height;
|
||||
final sWidth = size.width;
|
||||
return Container(
|
||||
margin: const EdgeInsets.only(top: 12, bottom: 6),
|
||||
padding: EdgeInsets.zero,
|
||||
|
Reference in New Issue
Block a user