Skip to content

Commit

Permalink
Fix location avability.
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanvorobei committed May 5, 2021
1 parent 11738f4 commit a622a08
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 19 deletions.
2 changes: 1 addition & 1 deletion SPPermissions.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|

s.name = "SPPermissions"
s.version = "5.5.6"
s.version = "5.5.7"
s.summary = "Ask permissions on Swift. Available List, Dialog & Native interface. Can check state permission."
s.homepage = "https://github.com/ivanvorobei/SPPermissions"
s.source = { :git => "https://github.com/ivanvorobei/SPPermissions.git", :tag => s.version }
Expand Down
28 changes: 15 additions & 13 deletions SPPermissions.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -657,7 +657,7 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 1120;
LastUpgradeCheck = 1120;
LastUpgradeCheck = 1250;
ORGANIZATIONNAME = "Ivan Vorobei";
TargetAttributes = {
9E50E9AD238B1EDD00B71477 = {
Expand Down Expand Up @@ -900,7 +900,7 @@
SDKROOT = appletvos;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = 3;
TVOS_DEPLOYMENT_TARGET = 11.0;
TVOS_DEPLOYMENT_TARGET = 12.0;
};
name = Debug;
};
Expand All @@ -921,15 +921,15 @@
SDKROOT = appletvos;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = 3;
TVOS_DEPLOYMENT_TARGET = 11.0;
TVOS_DEPLOYMENT_TARGET = 12.0;
};
name = Release;
};
9E50E9D2238B249C00B71477 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = F4FB9E9D2379E96E00F7272C /* SPPermissionsConfiguration.xcconfig */;
buildSettings = {
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_IDENTITY = "";
CODE_SIGN_STYLE = Automatic;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = 8JMTA2AAF3;
Expand All @@ -949,15 +949,15 @@
SKIP_INSTALL = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = 3;
TVOS_DEPLOYMENT_TARGET = 11.0;
TVOS_DEPLOYMENT_TARGET = 12.0;
};
name = Debug;
};
9E50E9D3238B249C00B71477 /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = F4FB9E9D2379E96E00F7272C /* SPPermissionsConfiguration.xcconfig */;
buildSettings = {
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_IDENTITY = "";
CODE_SIGN_STYLE = Automatic;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = 8JMTA2AAF3;
Expand All @@ -977,7 +977,7 @@
SKIP_INSTALL = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = 3;
TVOS_DEPLOYMENT_TARGET = 11.0;
TVOS_DEPLOYMENT_TARGET = 12.0;
};
name = Release;
};
Expand Down Expand Up @@ -1008,6 +1008,7 @@
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
Expand Down Expand Up @@ -1072,6 +1073,7 @@
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
Expand Down Expand Up @@ -1108,7 +1110,7 @@
baseConfigurationReference = F4FB9E9D2379E96E00F7272C /* SPPermissionsConfiguration.xcconfig */;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_IDENTITY = "";
CODE_SIGN_STYLE = Automatic;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = 8JMTA2AAF3;
Expand All @@ -1117,7 +1119,7 @@
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = "$(SRCROOT)/Sources/Supporting Files/SPPermissionsInfo.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -1137,7 +1139,7 @@
baseConfigurationReference = F4FB9E9D2379E96E00F7272C /* SPPermissionsConfiguration.xcconfig */;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_IDENTITY = "";
CODE_SIGN_STYLE = Automatic;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = 8JMTA2AAF3;
Expand All @@ -1146,7 +1148,7 @@
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = "$(SRCROOT)/Sources/Supporting Files/SPPermissionsInfo.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -1168,7 +1170,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = 8JMTA2AAF3;
INFOPLIST_FILE = "$(SRCROOT)/Example iOS/Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -1189,7 +1191,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = 8JMTA2AAF3;
INFOPLIST_FILE = "$(SRCROOT)/Example iOS/Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1120"
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1120"
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1120"
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1120"
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ class SPPermissionAlwaysAuthorizationLocationHandler: NSObject, CLLocationManage
}
#endif

#if SPPERMISSION_LOCATION
class SPPermissionWhenInUseAuthorizationLocationHandler: NSObject, CLLocationManagerDelegate {

static var shared: SPPermissionWhenInUseAuthorizationLocationHandler?
Expand Down Expand Up @@ -129,15 +130,18 @@ class SPPermissionWhenInUseAuthorizationLocationHandler: NSObject, CLLocationMan
locationManager.delegate = nil
}
}
#endif

#if os(iOS)
#if os(iOS) && SPPERMISSION_LOCATION
extension SPPermissionAlwaysAuthorizationLocationHandler {

typealias SPPermissionAuthorizationHandlerCompletionBlock = (Bool) -> Void
}
#endif

#if SPPERMISSION_LOCATION
extension SPPermissionWhenInUseAuthorizationLocationHandler {

typealias SPPermissionAuthorizationHandlerCompletionBlock = (Bool) -> Void
}
#endif

0 comments on commit a622a08

Please sign in to comment.