Skip to content

Commit

Permalink
feat: update to run on Flutter 3.7
Browse files Browse the repository at this point in the history
  • Loading branch information
Lyokone committed Mar 2, 2023
1 parent d8f90b2 commit bd11f67
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
.pub/
.dart_tool/
pubspec.lock
pubspec_overrides.yaml
flutter_export_environment.sh
coverage/

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@
<key>CFBundleVersion</key>
<string>1.0</string>
<key>MinimumOSVersion</key>
<string>9.0</string>
<string>11.0</string>
</dict>
</plist>
10 changes: 6 additions & 4 deletions packages/location/example/ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
objectVersion = 51;
objectVersion = 54;
objects = {

/* Begin PBXBuildFile section */
Expand Down Expand Up @@ -221,6 +221,7 @@
};
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
isa = PBXShellScriptBuildPhase;
alwaysOutOfDate = 1;
buildActionMask = 2147483647;
files = (
);
Expand Down Expand Up @@ -252,6 +253,7 @@
};
9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase;
alwaysOutOfDate = 1;
buildActionMask = 2147483647;
files = (
);
Expand Down Expand Up @@ -339,7 +341,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
Expand Down Expand Up @@ -418,7 +420,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -467,7 +469,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
Expand Down
2 changes: 2 additions & 0 deletions packages/location/example/ios/Runner/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,7 @@
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
</dict>
</plist>
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@
import com.lyokone.location.location.constants.RequestCode;
import com.lyokone.location.location.helper.LogUtils;
import com.lyokone.location.location.listener.FallbackListener;
import com.lyokone.location.location.providers.locationprovider.GooglePlayServicesLocationSource;
import com.lyokone.location.location.providers.locationprovider.GooglePlayServicesLocationSource.SourceListener;
import com.lyokone.location.location.providers.locationprovider.LocationProvider;

import java.lang.ref.WeakReference;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class GooglePlayServicesLocationSource extends LocationCallback {
private final FusedLocationProviderClient fusedLocationProviderClient;
private final LocationRequest locationRequest;
private final SourceListener sourceListener;
private final Context context;

interface SourceListener extends OnSuccessListener<LocationSettingsResponse>, OnFailureListener {
void onSuccess(LocationSettingsResponse locationSettingsResponse);
Expand All @@ -43,10 +44,11 @@ interface SourceListener extends OnSuccessListener<LocationSettingsResponse>, On
this.sourceListener = sourceListener;
this.locationRequest = locationRequest;
this.fusedLocationProviderClient = LocationServices.getFusedLocationProviderClient(context);
this.context = context;
}

void checkLocationSettings() {
LocationServices.getSettingsClient(fusedLocationProviderClient.getApplicationContext())
LocationServices.getSettingsClient(context)
.checkLocationSettings(
new LocationSettingsRequest.Builder()
.addLocationRequest(locationRequest)
Expand Down
7 changes: 7 additions & 0 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name: sharemail_workspace

environment:
sdk: ">=2.18.0 <3.0.0"

dev_dependencies:
melos: ^3.0.0-dev.0

0 comments on commit bd11f67

Please sign in to comment.