opt get sdkInt

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-07-22 12:19:48 +08:00
parent fbf47d7485
commit 4e5c4169fa
4 changed files with 14 additions and 9 deletions

View File

@@ -15,6 +15,16 @@ class Utils {
static const channel = MethodChannel("PiliPlus");
static int? _sdkInt;
static Future<int> get sdkInt async {
if (_sdkInt != null) {
return _sdkInt!;
}
_sdkInt = (await DeviceInfoPlugin().androidInfo).version.sdkInt;
return _sdkInt!;
}
static bool? _isIpad;
static Future<bool> isIpad() async {