Skip to content

Commit 03d14ad

Browse files
Update build target version and check memory space
1 parent 1f06cab commit 03d14ad

5 files changed

Lines changed: 25 additions & 30 deletions

File tree

example/ios/Flutter/AppFrameworkInfo.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@
2121
<key>CFBundleVersion</key>
2222
<string>1.0</string>
2323
<key>MinimumOSVersion</key>
24-
<string>9.0</string>
24+
<string>11.0</string>
2525
</dict>
2626
</plist>

example/ios/Podfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ EXTERNAL SOURCES:
3232
:path: ".symlinks/plugins/misnap_flutter/ios"
3333

3434
SPEC CHECKSUMS:
35-
Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a
35+
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
3636
MiSnap: 8915cfb803b839c9d5f985bcad298b2359d8024e
3737
misnap_flutter: bdee8404745277c54a695d761030013b7293bd57
3838
MiSnapAssetManager: a3650daeea15ce43d36716469537ee0e6cd5b8a2

example/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@
339339
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
340340
GCC_WARN_UNUSED_FUNCTION = YES;
341341
GCC_WARN_UNUSED_VARIABLE = YES;
342-
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
342+
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
343343
MTL_ENABLE_DEBUG_INFO = NO;
344344
SDKROOT = iphoneos;
345345
SUPPORTED_PLATFORMS = iphoneos;
@@ -417,7 +417,7 @@
417417
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
418418
GCC_WARN_UNUSED_FUNCTION = YES;
419419
GCC_WARN_UNUSED_VARIABLE = YES;
420-
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
420+
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
421421
MTL_ENABLE_DEBUG_INFO = YES;
422422
ONLY_ACTIVE_ARCH = YES;
423423
SDKROOT = iphoneos;
@@ -466,7 +466,7 @@
466466
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
467467
GCC_WARN_UNUSED_FUNCTION = YES;
468468
GCC_WARN_UNUSED_VARIABLE = YES;
469-
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
469+
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
470470
MTL_ENABLE_DEBUG_INFO = NO;
471471
SDKROOT = iphoneos;
472472
SUPPORTED_PLATFORMS = iphoneos;

ios/Classes/SwiftMisnapFlutterPlugin.swift

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ public class SwiftMisnapFlutterPlugin: NSObject, FlutterPlugin {
1212
let channel = FlutterMethodChannel(name: "misnap_flutter", binaryMessenger: registrar.messenger())
1313
let instance = SwiftMisnapFlutterPlugin()
1414
registrar.addMethodCallDelegate(instance, channel: channel)
15+
16+
MiSnapLicenseManager.shared().setLicenseKey("your-license-key-here")
1517
}
1618

1719
public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
@@ -69,6 +71,12 @@ public class SwiftMisnapFlutterPlugin: NSObject, FlutterPlugin {
6971

7072
let viewController = UIApplication.shared.windows.last?.rootViewController
7173

74+
let minDiskSpace: Int = 20
75+
if !misnapVC.hasMinDiskSpace(minDiskSpace) {
76+
self.presentAlert(withTitle: "Not Enough Space", message: "Please, delete old/unused files to have at least \(minDiskSpace) MB of free space", viewController: viewController)
77+
return
78+
}
79+
7280
misnapVC.checkCameraPermission { granted in
7381
if !granted {
7482
let message = "Camera permission is required to capture your documents."
@@ -81,12 +89,6 @@ public class SwiftMisnapFlutterPlugin: NSObject, FlutterPlugin {
8189
}
8290
}
8391

84-
let minDiskSpace: Int = 20
85-
if !misnapVC.hasMinDiskSpace(minDiskSpace) {
86-
self.presentAlert(withTitle: "Not Enough Space", message: "Please, delete old/unused files to have at least \(minDiskSpace) MB of free space", viewController: viewController)
87-
return
88-
}
89-
9092
self.misnapVC = misnapVC
9193
}
9294

pubspec.lock

Lines changed: 12 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ packages:
77
name: async
88
url: "https://pub.dartlang.org"
99
source: hosted
10-
version: "2.8.2"
10+
version: "2.9.0"
1111
boolean_selector:
1212
dependency: transitive
1313
description:
@@ -21,21 +21,14 @@ packages:
2121
name: characters
2222
url: "https://pub.dartlang.org"
2323
source: hosted
24-
version: "1.2.0"
25-
charcode:
26-
dependency: transitive
27-
description:
28-
name: charcode
29-
url: "https://pub.dartlang.org"
30-
source: hosted
31-
version: "1.3.1"
24+
version: "1.2.1"
3225
clock:
3326
dependency: transitive
3427
description:
3528
name: clock
3629
url: "https://pub.dartlang.org"
3730
source: hosted
38-
version: "1.1.0"
31+
version: "1.1.1"
3932
collection:
4033
dependency: transitive
4134
description:
@@ -49,7 +42,7 @@ packages:
4942
name: fake_async
5043
url: "https://pub.dartlang.org"
5144
source: hosted
52-
version: "1.3.0"
45+
version: "1.3.1"
5346
flutter:
5447
dependency: "direct main"
5548
description: flutter
@@ -80,28 +73,28 @@ packages:
8073
name: matcher
8174
url: "https://pub.dartlang.org"
8275
source: hosted
83-
version: "0.12.11"
76+
version: "0.12.12"
8477
material_color_utilities:
8578
dependency: transitive
8679
description:
8780
name: material_color_utilities
8881
url: "https://pub.dartlang.org"
8982
source: hosted
90-
version: "0.1.4"
83+
version: "0.1.5"
9184
meta:
9285
dependency: transitive
9386
description:
9487
name: meta
9588
url: "https://pub.dartlang.org"
9689
source: hosted
97-
version: "1.7.0"
90+
version: "1.8.0"
9891
path:
9992
dependency: transitive
10093
description:
10194
name: path
10295
url: "https://pub.dartlang.org"
10396
source: hosted
104-
version: "1.8.1"
97+
version: "1.8.2"
10598
plugin_platform_interface:
10699
dependency: "direct main"
107100
description:
@@ -120,7 +113,7 @@ packages:
120113
name: source_span
121114
url: "https://pub.dartlang.org"
122115
source: hosted
123-
version: "1.8.2"
116+
version: "1.9.0"
124117
stack_trace:
125118
dependency: transitive
126119
description:
@@ -141,21 +134,21 @@ packages:
141134
name: string_scanner
142135
url: "https://pub.dartlang.org"
143136
source: hosted
144-
version: "1.1.0"
137+
version: "1.1.1"
145138
term_glyph:
146139
dependency: transitive
147140
description:
148141
name: term_glyph
149142
url: "https://pub.dartlang.org"
150143
source: hosted
151-
version: "1.2.0"
144+
version: "1.2.1"
152145
test_api:
153146
dependency: transitive
154147
description:
155148
name: test_api
156149
url: "https://pub.dartlang.org"
157150
source: hosted
158-
version: "0.4.9"
151+
version: "0.4.12"
159152
vector_math:
160153
dependency: transitive
161154
description:

0 commit comments

Comments
 (0)