git lixo 2
This commit is contained in:
@@ -1 +1,11 @@
|
||||
// TODO Implement this library.
|
||||
import 'package:flutter/material.dart';
|
||||
import 'dart:math' as math;
|
||||
|
||||
extension SizeExtension on BuildContext {
|
||||
double get sf {
|
||||
final double wScreen = MediaQuery.of(this).size.width;
|
||||
final double hScreen = MediaQuery.of(this).size.height;
|
||||
// Ajusta a escala baseada no ecrã (muda os valores 1150/720 conforme a tua calibração)
|
||||
return math.min(wScreen / 1150, hScreen / 720);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user