diff --git a/android/app/build.gradle b/android/app/build.gradle index 3d648f8..b02a40f 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -45,7 +45,7 @@ android { // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). applicationId "com.makan.face_auth_flutter" minSdkVersion 21 - targetSdkVersion flutter.targetSdkVersion + targetSdkVersion 31 versionCode flutterVersionCode.toInteger() versionName flutterVersionName } diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index 3692221..501640b 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -1,9 +1,9 @@ + android:icon="@mipmap/launcher_icon"> const MaterialApp( debugShowCheckedModeBanner: false, title: "Face Auth", - home: LoginPage(), + home: Detection(), ); } diff --git a/lib/page/login_page.dart b/lib/page/detection.dart similarity index 67% rename from lib/page/login_page.dart rename to lib/page/detection.dart index a1a122d..8e54f9c 100644 --- a/lib/page/login_page.dart +++ b/lib/page/detection.dart @@ -1,17 +1,18 @@ import 'package:face_auth_flutter/page/face_recognition/camera_page.dart'; +import 'package:face_auth_flutter/page/login_view.dart'; import 'package:face_auth_flutter/utils/local_db.dart'; import 'package:flutter/material.dart'; import '../utils/utils.dart'; -class LoginPage extends StatefulWidget { - const LoginPage({Key? key}) : super(key: key); +class Detection extends StatefulWidget { + const Detection({Key? key}) : super(key: key); @override - State createState() => _LoginPageState(); + State createState() => _DetectionState(); } -class _LoginPageState extends State { +class _DetectionState extends State { @override void initState() { printIfDebug(LocalDB.getUser().name); @@ -21,8 +22,8 @@ class _LoginPageState extends State { @override Widget build(BuildContext context) => Scaffold( appBar: AppBar( - title: const Text("Face Authentication"), - centerTitle: true, + backgroundColor: Colors.transparent, + title: Image.asset("assets/metro2.png"), ), body: Padding( padding: const EdgeInsets.all(32), @@ -34,10 +35,7 @@ class _LoginPageState extends State { text: 'Register', icon: Icons.app_registration_rounded, onClicked: () async { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const FaceScanScreen())); + Navigator.push(context, MaterialPageRoute(builder: (context) => const FaceScanScreen())); }, ), const SizedBox(height: 24), @@ -45,12 +43,7 @@ class _LoginPageState extends State { text: 'Login', icon: Icons.login, onClicked: () async { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => FaceScanScreen( - user: LocalDB.getUser(), - ))); + Navigator.push(context, MaterialPageRoute(builder: (context) => const LoginView())); }, ), ], @@ -66,6 +59,7 @@ class _LoginPageState extends State { }) => ElevatedButton.icon( style: ElevatedButton.styleFrom( + backgroundColor: Colors.black26, minimumSize: const Size.fromHeight(50), ), icon: Icon(icon, size: 26), diff --git a/lib/page/face_recognition/camera_page.dart b/lib/page/face_recognition/camera_page.dart index b7a37a6..ed22be6 100644 --- a/lib/page/face_recognition/camera_page.dart +++ b/lib/page/face_recognition/camera_page.dart @@ -49,8 +49,7 @@ class _FaceScanScreenState extends State { Future detectFacesFromImage(CameraImage image) async { InputImageData _firebaseImageMetadata = InputImageData( - imageRotation: rotationIntToImageRotation( - _cameraController.description.sensorOrientation), + imageRotation: rotationIntToImageRotation(_cameraController.description.sensorOrientation), inputImageFormat: InputImageFormat.BGRA8888, size: Size(image.width.toDouble(), image.height.toDouble()), planeData: image.planes.map( @@ -78,10 +77,7 @@ class _FaceScanScreenState extends State { await detectFacesFromImage(image); if (facesDetected.isNotEmpty) { User? user = await _mlService.predict( - image, - facesDetected[0], - widget.user != null, - widget.user != null ? widget.user!.name! : controller.text); + image, facesDetected[0], widget.user != null, widget.user != null ? widget.user!.name! : controller.text); if (widget.user == null) { // register case Navigator.pop(context); @@ -92,8 +88,7 @@ class _FaceScanScreenState extends State { Navigator.pop(context); print("Unknown User"); } else { - Navigator.push(context, - MaterialPageRoute(builder: (context) => const HomePage())); + Navigator.push(context, MaterialPageRoute(builder: (context) => const HomePage())); } } } @@ -108,10 +103,7 @@ class _FaceScanScreenState extends State { file = XFile(file.path); _cameraController.setFlashMode(FlashMode.off); } else { - showDialog( - context: context, - builder: (context) => - const AlertDialog(content: Text('No face detected!'))); + showDialog(context: context, builder: (context) => const AlertDialog(content: Text('No face detected!'))); } } @@ -144,9 +136,7 @@ class _FaceScanScreenState extends State { SizedBox( width: MediaQuery.of(context).size.width, height: MediaQuery.of(context).size.height, - child: isControllerInitialized - ? CameraPreview(_cameraController) - : null), + child: isControllerInitialized ? CameraPreview(_cameraController) : null), Center( child: Column( mainAxisAlignment: MainAxisAlignment.start, @@ -154,14 +144,12 @@ class _FaceScanScreenState extends State { Expanded( child: Padding( padding: const EdgeInsets.only(bottom: 100), - child: Lottie.asset("assets/loading.json", - width: MediaQuery.of(context).size.width * 0.7), + child: Lottie.asset("assets/loading.json", width: MediaQuery.of(context).size.width * 0.7), ), ), TextField( controller: controller, - decoration: const InputDecoration( - fillColor: Colors.white, filled: true), + decoration: const InputDecoration(fillColor: Colors.white, filled: true), ), Row( mainAxisAlignment: MainAxisAlignment.center, @@ -172,7 +160,7 @@ class _FaceScanScreenState extends State { text: "Capture", context: context, isClickable: true, - onTap: (){ + onTap: () { bool canProcess = false; _cameraController.startImageStream((CameraImage image) async { if (canProcess) return; @@ -195,8 +183,7 @@ class _FaceScanScreenState extends State { flash = !flash; }); flash - ? _cameraController - .setFlashMode(FlashMode.torch) + ? _cameraController.setFlashMode(FlashMode.torch) : _cameraController.setFlashMode(FlashMode.off); }), ], diff --git a/lib/page/home_page.dart b/lib/page/home_page.dart index 84f79ed..8d8bf26 100644 --- a/lib/page/home_page.dart +++ b/lib/page/home_page.dart @@ -1,4 +1,4 @@ -import 'package:face_auth_flutter/page/login_page.dart'; +import 'package:face_auth_flutter/page/detection.dart'; import 'package:face_auth_flutter/utils/local_db.dart'; import 'package:flutter/material.dart'; @@ -37,7 +37,7 @@ class HomePage extends StatelessWidget { style: TextStyle(fontSize: 20), ), onPressed: () => Navigator.of(context).pushReplacement( - MaterialPageRoute(builder: (context) => const LoginPage()), + MaterialPageRoute(builder: (context) => const Detection()), ), ); } diff --git a/lib/page/login_view.dart b/lib/page/login_view.dart new file mode 100644 index 0000000..ad87cb8 --- /dev/null +++ b/lib/page/login_view.dart @@ -0,0 +1,67 @@ +import 'package:face_auth_flutter/page/face_recognition/camera_page.dart'; +import 'package:flutter/material.dart'; + +class LoginView extends StatefulWidget { + const LoginView({ + Key? key, + }) : super(key: key); + + @override + State createState() => _LoginViewState(); +} + +class _LoginViewState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + body: Center( + child: SizedBox( + height: 500, + child: Column( + children: [ + const Padding( + padding: EdgeInsets.all(8.0), + child: CustomText(text: "İsim"), + ), + const Padding( + padding: EdgeInsets.all(8.0), + child: CustomText(text: "Soyisim"), + ), + const Padding( + padding: EdgeInsets.all(8.0), + child: CustomText(text: "Sicil No"), + ), + ElevatedButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const FaceScanScreen(), + )); + }, + child: const Text("Giriş Yap")) + ], + ), + ), + ), + ); + } +} + +class CustomText extends StatelessWidget { + final String text; + const CustomText({ + Key? key, + required this.text, + }) : super(key: key); + + @override + Widget build(BuildContext context) { + return TextField( + decoration: InputDecoration( + labelText: text, + border: const OutlineInputBorder(borderSide: BorderSide(color: Colors.black)), + errorBorder: const OutlineInputBorder(borderSide: BorderSide(color: Colors.black))), + ); + } +} diff --git a/pubspec.lock b/pubspec.lock index 623404a..8ace54a 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -5,133 +5,159 @@ packages: dependency: transitive description: name: archive - url: "https://pub.dartlang.org" + sha256: "0c8368c9b3f0abbc193b9d6133649a614204b528982bebc7026372d61677ce3a" + url: "https://pub.dev" source: hosted - version: "3.3.0" + version: "3.3.7" + args: + dependency: transitive + description: + name: args + sha256: eef6c46b622e0494a36c5a12d10d77fb4e855501a91c1b9ef9339326e58f0596 + url: "https://pub.dev" + source: hosted + version: "2.4.2" async: dependency: transitive description: name: async - url: "https://pub.dartlang.org" + sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" + url: "https://pub.dev" source: hosted - version: "2.8.2" + version: "2.11.0" boolean_selector: dependency: transitive description: name: boolean_selector - url: "https://pub.dartlang.org" + sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" + url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.1.1" camera: dependency: "direct main" description: name: camera - url: "https://pub.dartlang.org" + sha256: "79e9a4729f4f9f42c37a7aeac5daf8494495f1e41cc1588fa703162d0426457f" + url: "https://pub.dev" source: hosted version: "0.9.4+18" camera_platform_interface: dependency: transitive description: name: camera_platform_interface - url: "https://pub.dartlang.org" + sha256: "60fa0bb62a4f3bf3a7c413e31e4cd01b69c779ccc8e4668904a24581b86c316b" + url: "https://pub.dev" source: hosted - version: "2.2.0" + version: "2.5.1" camera_web: dependency: transitive description: name: camera_web - url: "https://pub.dartlang.org" + sha256: "18cdbee5441e9a6fb129fdd9b68a06d1b8c5236932ba97d5faeaefe80db2e5bd" + url: "https://pub.dev" source: hosted version: "0.2.1+6" characters: dependency: transitive description: name: characters - url: "https://pub.dartlang.org" + sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" + url: "https://pub.dev" source: hosted - version: "1.2.0" - charcode: - dependency: transitive - description: - name: charcode - url: "https://pub.dartlang.org" - source: hosted - version: "1.3.1" + version: "1.3.0" clock: dependency: transitive description: name: clock - url: "https://pub.dartlang.org" + sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf + url: "https://pub.dev" source: hosted - version: "1.1.0" + version: "1.1.1" collection: dependency: transitive description: name: collection - url: "https://pub.dartlang.org" + sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c" + url: "https://pub.dev" source: hosted - version: "1.15.0" + version: "1.17.1" + convert: + dependency: transitive + description: + name: convert + sha256: "0f08b14755d163f6e2134cb58222dd25ea2a2ee8a195e53983d57c075324d592" + url: "https://pub.dev" + source: hosted + version: "3.1.1" cross_file: dependency: transitive description: name: cross_file - url: "https://pub.dartlang.org" + sha256: "0b0036e8cccbfbe0555fd83c1d31a6f30b77a96b598b35a5d36dd41f718695e9" + url: "https://pub.dev" source: hosted - version: "0.3.3+1" + version: "0.3.3+4" crypto: dependency: transitive description: name: crypto - url: "https://pub.dartlang.org" + sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab + url: "https://pub.dev" source: hosted - version: "3.0.2" + version: "3.0.3" cupertino_icons: dependency: "direct main" description: name: cupertino_icons - url: "https://pub.dartlang.org" + sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be + url: "https://pub.dev" source: hosted version: "1.0.5" fake_async: dependency: transitive description: name: fake_async - url: "https://pub.dartlang.org" + sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78" + url: "https://pub.dev" source: hosted - version: "1.2.0" + version: "1.3.1" ffi: dependency: transitive description: name: ffi - url: "https://pub.dartlang.org" - source: hosted - version: "1.2.1" - file: - dependency: transitive - description: - name: file - url: "https://pub.dartlang.org" + sha256: ed5337a5660c506388a9f012be0288fb38b49020ce2b45fe1f8b8323fe429f99 + url: "https://pub.dev" source: hosted - version: "6.1.2" + version: "2.0.2" flutter: dependency: "direct main" description: flutter source: sdk version: "0.0.0" + flutter_launcher_icons: + dependency: "direct dev" + description: + name: flutter_launcher_icons + sha256: "559c600f056e7c704bd843723c21e01b5fba47e8824bd02422165bcc02a5de1d" + url: "https://pub.dev" + source: hosted + version: "0.9.3" flutter_lints: dependency: "direct dev" description: name: flutter_lints - url: "https://pub.dartlang.org" + sha256: b543301ad291598523947dc534aaddc5aaad597b709d2426d3a0e0d44c5cb493 + url: "https://pub.dev" source: hosted version: "1.0.4" flutter_plugin_android_lifecycle: dependency: transitive description: name: flutter_plugin_android_lifecycle - url: "https://pub.dartlang.org" + sha256: "950e77c2bbe1692bc0874fc7fb491b96a4dc340457f4ea1641443d0a6c1ea360" + url: "https://pub.dev" source: hosted - version: "2.0.6" + version: "2.0.15" flutter_test: dependency: "direct dev" description: flutter @@ -146,163 +172,178 @@ packages: dependency: "direct main" description: name: google_ml_kit - url: "https://pub.dartlang.org" + sha256: "1bfe11253fdcb5da7903ec465c8144517969e9fd1bbb1f87a5010c9648641e91" + url: "https://pub.dev" source: hosted version: "0.7.3" hive: dependency: transitive description: name: hive - url: "https://pub.dartlang.org" + sha256: "8dcf6db979d7933da8217edcec84e9df1bdb4e4edc7fc77dbd5aa74356d6d941" + url: "https://pub.dev" source: hosted - version: "2.2.1" + version: "2.2.3" hive_flutter: dependency: "direct main" description: name: hive_flutter - url: "https://pub.dartlang.org" + sha256: dca1da446b1d808a51689fb5d0c6c9510c0a2ba01e22805d492c73b68e33eecc + url: "https://pub.dev" source: hosted version: "1.1.0" image: dependency: "direct main" description: name: image - url: "https://pub.dartlang.org" + sha256: "8e9d133755c3e84c73288363e6343157c383a0c6c56fc51afcc5d4d7180306d6" + url: "https://pub.dev" source: hosted - version: "3.1.3" + version: "3.3.0" js: dependency: transitive description: name: js - url: "https://pub.dartlang.org" + sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3 + url: "https://pub.dev" source: hosted - version: "0.6.3" + version: "0.6.7" lints: dependency: transitive description: name: lints - url: "https://pub.dartlang.org" + sha256: a2c3d198cb5ea2e179926622d433331d8b58374ab8f29cdda6e863bd62fd369c + url: "https://pub.dev" source: hosted version: "1.0.1" lottie: dependency: "direct main" description: name: lottie - url: "https://pub.dartlang.org" + sha256: "893da7a0022ec2fcaa616f34529a081f617e86cc501105b856e5a3184c58c7c2" + url: "https://pub.dev" source: hosted - version: "1.3.0" + version: "1.4.3" matcher: dependency: transitive description: name: matcher - url: "https://pub.dartlang.org" + sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb" + url: "https://pub.dev" source: hosted - version: "0.12.11" + version: "0.12.15" material_color_utilities: dependency: transitive description: name: material_color_utilities - url: "https://pub.dartlang.org" + sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 + url: "https://pub.dev" source: hosted - version: "0.1.3" + version: "0.2.0" meta: dependency: transitive description: name: meta - url: "https://pub.dartlang.org" + sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + url: "https://pub.dev" source: hosted - version: "1.7.0" + version: "1.9.1" path: dependency: transitive description: name: path - url: "https://pub.dartlang.org" + sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" + url: "https://pub.dev" source: hosted - version: "1.8.0" + version: "1.8.3" path_provider: dependency: transitive description: name: path_provider - url: "https://pub.dartlang.org" + sha256: "3087813781ab814e4157b172f1a11c46be20179fcc9bea043e0fba36bc0acaa2" + url: "https://pub.dev" source: hosted - version: "2.0.11" + version: "2.0.15" path_provider_android: dependency: transitive description: name: path_provider_android - url: "https://pub.dartlang.org" + sha256: "2cec049d282c7f13c594b4a73976b0b4f2d7a1838a6dd5aaf7bd9719196bee86" + url: "https://pub.dev" source: hosted - version: "2.0.14" - path_provider_ios: + version: "2.0.27" + path_provider_foundation: dependency: transitive description: - name: path_provider_ios - url: "https://pub.dartlang.org" + name: path_provider_foundation + sha256: "916731ccbdce44d545414dd9961f26ba5fbaa74bcbb55237d8e65a623a8c7297" + url: "https://pub.dev" source: hosted - version: "2.0.9" + version: "2.2.4" path_provider_linux: dependency: transitive description: name: path_provider_linux - url: "https://pub.dartlang.org" - source: hosted - version: "2.1.7" - path_provider_macos: - dependency: transitive - description: - name: path_provider_macos - url: "https://pub.dartlang.org" + sha256: ffbb8cc9ed2c9ec0e4b7a541e56fd79b138e8f47d2fb86815f15358a349b3b57 + url: "https://pub.dev" source: hosted - version: "2.0.6" + version: "2.1.11" path_provider_platform_interface: dependency: transitive description: name: path_provider_platform_interface - url: "https://pub.dartlang.org" + sha256: "57585299a729335f1298b43245842678cb9f43a6310351b18fb577d6e33165ec" + url: "https://pub.dev" source: hosted - version: "2.0.4" + version: "2.0.6" path_provider_windows: dependency: transitive description: name: path_provider_windows - url: "https://pub.dartlang.org" + sha256: "1cb68ba4cd3a795033de62ba1b7b4564dace301f952de6bfb3cd91b202b6ee96" + url: "https://pub.dev" source: hosted - version: "2.0.7" + version: "2.1.7" petitparser: dependency: transitive description: name: petitparser - url: "https://pub.dartlang.org" + sha256: cb3798bef7fc021ac45b308f4b51208a152792445cce0448c9a4ba5879dd8750 + url: "https://pub.dev" source: hosted - version: "4.4.0" + version: "5.4.0" platform: dependency: transitive description: name: platform - url: "https://pub.dartlang.org" + sha256: "4a451831508d7d6ca779f7ac6e212b4023dd5a7d08a27a63da33756410e32b76" + url: "https://pub.dev" source: hosted version: "3.1.0" plugin_platform_interface: dependency: transitive description: name: plugin_platform_interface - url: "https://pub.dartlang.org" + sha256: "6a2128648c854906c53fa8e33986fc0247a1116122f9534dd20e3ab9e16a32bc" + url: "https://pub.dev" source: hosted - version: "2.1.2" - process: + version: "2.1.4" + pointycastle: dependency: transitive description: - name: process - url: "https://pub.dartlang.org" + name: pointycastle + sha256: "7c1e5f0d23c9016c5bbd8b1473d0d3fb3fc851b876046039509e18e0c7485f2c" + url: "https://pub.dev" source: hosted - version: "4.2.4" + version: "3.7.3" quiver: dependency: transitive description: name: quiver - url: "https://pub.dartlang.org" + sha256: b1c1ac5ce6688d77f65f3375a9abb9319b3cb32486bdc7a1e0fdf004d7ba4e47 + url: "https://pub.dev" source: hosted - version: "3.1.0" + version: "3.2.1" sky_engine: dependency: transitive description: flutter @@ -312,93 +353,114 @@ packages: dependency: transitive description: name: source_span - url: "https://pub.dartlang.org" + sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 + url: "https://pub.dev" source: hosted - version: "1.8.1" + version: "1.9.1" stack_trace: dependency: transitive description: name: stack_trace - url: "https://pub.dartlang.org" + sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 + url: "https://pub.dev" source: hosted - version: "1.10.0" + version: "1.11.0" stream_channel: dependency: transitive description: name: stream_channel - url: "https://pub.dartlang.org" + sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" + url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.1.1" stream_transform: dependency: transitive description: name: stream_transform - url: "https://pub.dartlang.org" + sha256: "14a00e794c7c11aa145a170587321aedce29769c08d7f58b1d141da75e3b1c6f" + url: "https://pub.dev" source: hosted - version: "2.0.0" + version: "2.1.0" string_scanner: dependency: transitive description: name: string_scanner - url: "https://pub.dartlang.org" + sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" + url: "https://pub.dev" source: hosted - version: "1.1.0" + version: "1.2.0" term_glyph: dependency: transitive description: name: term_glyph - url: "https://pub.dartlang.org" + sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 + url: "https://pub.dev" source: hosted - version: "1.2.0" + version: "1.2.1" test_api: dependency: transitive description: name: test_api - url: "https://pub.dartlang.org" + sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb + url: "https://pub.dev" source: hosted - version: "0.4.8" + version: "0.5.1" tflite_flutter: dependency: "direct main" description: name: tflite_flutter - url: "https://pub.dartlang.org" + sha256: "88b203c6efd7f4269aa137ef31e760d53e6639e60cd17bb86602462f72d4176b" + url: "https://pub.dev" source: hosted - version: "0.9.0" + version: "0.9.5" typed_data: dependency: transitive description: name: typed_data - url: "https://pub.dartlang.org" + sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c + url: "https://pub.dev" source: hosted - version: "1.3.0" + version: "1.3.2" vector_math: dependency: transitive description: name: vector_math - url: "https://pub.dartlang.org" + sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" + url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.4" win32: dependency: transitive description: name: win32 - url: "https://pub.dartlang.org" + sha256: dfdf0136e0aa7a1b474ea133e67cb0154a0acd2599c4f3ada3b49d38d38793ee + url: "https://pub.dev" source: hosted - version: "2.5.2" + version: "5.0.5" xdg_directories: dependency: transitive description: name: xdg_directories - url: "https://pub.dartlang.org" + sha256: e0b1147eec179d3911f1f19b59206448f78195ca1d20514134e10641b7d7fbff + url: "https://pub.dev" source: hosted - version: "0.2.0+1" + version: "1.0.1" xml: dependency: transitive description: name: xml - url: "https://pub.dartlang.org" + sha256: "5bc72e1e45e941d825fd7468b9b4cc3b9327942649aeb6fc5cdbf135f0a86e84" + url: "https://pub.dev" + source: hosted + version: "6.3.0" + yaml: + dependency: transitive + description: + name: yaml + sha256: "75769501ea3489fca56601ff33454fe45507ea3bfb014161abc3b43ae25989d5" + url: "https://pub.dev" source: hosted - version: "5.3.1" + version: "3.1.2" sdks: - dart: ">=2.16.1 <3.0.0" - flutter: ">=2.10.0" + dart: ">=3.0.0 <4.0.0" + flutter: ">=3.3.0" diff --git a/pubspec.yaml b/pubspec.yaml index a6ef1fa..7ba5848 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -37,20 +37,23 @@ dependencies: hive_flutter: ^1.1.0 camera: 0.9.4+18 tflite_flutter: ^0.9.0 - google_ml_kit: 0.7.3 - image: 3.1.3 + google_ml_kit: ^0.7.3 + image: ^3.1.3 lottie: ^1.2.2 dev_dependencies: flutter_test: sdk: flutter - # The "flutter_lints" package below contains a set of recommended lints to - # encourage good coding practices. The lint set provided by the package is - # activated in the `analysis_options.yaml` file located at the root of your - # package. See that file for information about deactivating specific lint - # rules and activating additional ones. flutter_lints: ^1.0.0 + flutter_launcher_icons: "^0.9.2" + +flutter_icons: + android: "launcher_icon" + ios: true + image_path: "assets/icon/metro.png" + + # For information on the generic Dart part of this file, see the # following page: https://dart.dev/tools/pub/pubspec diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake index 4d10c25..b93c4c3 100644 --- a/windows/flutter/generated_plugins.cmake +++ b/windows/flutter/generated_plugins.cmake @@ -5,6 +5,9 @@ list(APPEND FLUTTER_PLUGIN_LIST ) +list(APPEND FLUTTER_FFI_PLUGIN_LIST +) + set(PLUGIN_BUNDLED_LIBRARIES) foreach(plugin ${FLUTTER_PLUGIN_LIST}) @@ -13,3 +16,8 @@ foreach(plugin ${FLUTTER_PLUGIN_LIST}) list(APPEND PLUGIN_BUNDLED_LIBRARIES $) list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) endforeach(plugin) + +foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) +endforeach(ffi_plugin)