Skip to content

Commit bd6dc5b

Browse files
author
Egor Lindberg
committed
Upload to cocoapods and add spm support
1 parent 64b04dc commit bd6dc5b

File tree

66 files changed

+2868
-746
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+2868
-746
lines changed

.swift-version

Lines changed: 0 additions & 1 deletion
This file was deleted.

Example/ORLocation.xcodeproj/project.pbxproj

Lines changed: 93 additions & 103 deletions
Large diffs are not rendered by default.

Example/ORLocation.xcodeproj/xcshareddata/xcschemes/ORLocation-Example.xcscheme

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "0800"
3+
LastUpgradeVersion = "0900"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "YES"
@@ -40,6 +40,7 @@
4040
buildConfiguration = "Debug"
4141
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
4242
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
43+
language = ""
4344
shouldUseLaunchSchemeArgsEnv = "YES">
4445
<Testables>
4546
<TestableReference
@@ -69,6 +70,7 @@
6970
buildConfiguration = "Debug"
7071
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
7172
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
73+
language = ""
7274
launchStyle = "0"
7375
useCustomWorkingDirectory = "NO"
7476
ignoresPersistentStateOnLaunch = "NO"

Example/ORLocation/AppDelegate.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
// AppDelegate.swift
33
// ORLocation
44
//
5-
// Created by Maxim Soloviev on 09/11/2016.
6-
// Copyright (c) 2016 Maxim Soloviev. All rights reserved.
5+
// Created by Egor Lindberg on 01/19/2021.
6+
// Copyright (c) 2021 Egor Lindberg. All rights reserved.
77
//
88

99
import UIKit

Example/ORLocation/Base.lproj/LaunchScreen.xib

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,13 @@
1-
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2-
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="6214" systemVersion="14A314h" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES">
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="13771" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" colorMatched="YES">
3+
<device id="retina4_7" orientation="portrait">
4+
<adaptation id="fullscreen"/>
5+
</device>
36
<dependencies>
4-
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6207"/>
7+
<deployment identifier="iOS"/>
8+
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13772"/>
59
<capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>
10+
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
611
</dependencies>
712
<objects>
813
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
@@ -24,7 +29,7 @@
2429
<nil key="highlightedColor"/>
2530
</label>
2631
</subviews>
27-
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
32+
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
2833
<constraints>
2934
<constraint firstItem="kId-c2-rCX" firstAttribute="centerY" secondItem="iN0-l3-epB" secondAttribute="bottom" multiplier="1/3" constant="1" id="5cJ-9S-tgC"/>
3035
<constraint firstAttribute="centerX" secondItem="kId-c2-rCX" secondAttribute="centerX" id="Koa-jz-hwk"/>

Example/ORLocation/Base.lproj/Main.storyboard

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13196" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="vXZ-lx-hvc">
2+
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13771" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="vXZ-lx-hvc">
33
<device id="retina4_7" orientation="portrait">
44
<adaptation id="fullscreen"/>
55
</device>
66
<dependencies>
77
<deployment identifier="iOS"/>
8-
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13173"/>
8+
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13772"/>
99
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
1010
</dependencies>
1111
<scenes>
@@ -20,24 +20,8 @@
2020
<view key="view" contentMode="scaleToFill" id="kh9-bI-dsS">
2121
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
2222
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
23-
<subviews>
24-
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="coordinates" textAlignment="center" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="FRx-3h-ei3">
25-
<rect key="frame" x="8" y="323" width="359" height="21"/>
26-
<fontDescription key="fontDescription" type="system" pointSize="17"/>
27-
<nil key="textColor"/>
28-
<nil key="highlightedColor"/>
29-
</label>
30-
</subviews>
3123
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
32-
<constraints>
33-
<constraint firstItem="FRx-3h-ei3" firstAttribute="leading" secondItem="kh9-bI-dsS" secondAttribute="leading" constant="8" id="Qag-MN-7kJ"/>
34-
<constraint firstItem="FRx-3h-ei3" firstAttribute="centerY" secondItem="kh9-bI-dsS" secondAttribute="centerY" id="ZEh-dl-ClZ"/>
35-
<constraint firstAttribute="trailing" secondItem="FRx-3h-ei3" secondAttribute="trailing" constant="8" id="mLa-Yr-jUm"/>
36-
</constraints>
3724
</view>
38-
<connections>
39-
<outlet property="labelCoord" destination="FRx-3h-ei3" id="6j7-KI-4hM"/>
40-
</connections>
4125
</viewController>
4226
<placeholder placeholderIdentifier="IBFirstResponder" id="x5A-6p-PRh" sceneMemberID="firstResponder"/>
4327
</objects>

Example/ORLocation/Images.xcassets/AppIcon.appiconset/Contents.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
11
{
22
"images" : [
3+
{
4+
"idiom" : "iphone",
5+
"size" : "20x20",
6+
"scale" : "2x"
7+
},
8+
{
9+
"idiom" : "iphone",
10+
"size" : "20x20",
11+
"scale" : "3x"
12+
},
313
{
414
"idiom" : "iphone",
515
"size" : "29x29",
@@ -29,6 +39,11 @@
2939
"idiom" : "iphone",
3040
"size" : "60x60",
3141
"scale" : "3x"
42+
},
43+
{
44+
"idiom" : "ios-marketing",
45+
"size" : "1024x1024",
46+
"scale" : "1x"
3247
}
3348
],
3449
"info" : {

Example/ORLocation/Info.plist

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@
2020
<string>????</string>
2121
<key>CFBundleVersion</key>
2222
<string>1</string>
23-
<key>NSLocationWhenInUseUsageDescription</key>
24-
<string>Please authorize location usage</string>
2523
<key>LSRequiresIPhoneOS</key>
2624
<true/>
2725
<key>UILaunchStoryboardName</key>

Example/ORLocation/ViewController.swift

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,23 @@
22
// ViewController.swift
33
// ORLocation
44
//
5-
// Created by Maxim Soloviev on 09/11/2016.
6-
// Copyright (c) 2016 Maxim Soloviev. All rights reserved.
5+
// Created by Egor Lindberg on 01/19/2021.
6+
// Copyright (c) 2021 Egor Lindberg. All rights reserved.
77
//
88

99
import UIKit
10-
import ORLocation
1110

1211
class ViewController: UIViewController {
1312

14-
@IBOutlet weak var labelCoord: UILabel!
15-
1613
override func viewDidLoad() {
1714
super.viewDidLoad()
18-
19-
ORCurrentLocationDetector.shared.detect { (loc) in
20-
self.labelCoord.text = loc != nil ? "\(loc!)" : "nil"
21-
}
15+
// Do any additional setup after loading the view, typically from a nib.
2216
}
17+
18+
override func didReceiveMemoryWarning() {
19+
super.didReceiveMemoryWarning()
20+
// Dispose of any resources that can be recreated.
21+
}
22+
2323
}
24+

Example/Podfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
use_frameworks!
22

3+
platform :ios, '9.0'
4+
35
target 'ORLocation_Example' do
46
pod 'ORLocation', :path => '../'
57

68
target 'ORLocation_Tests' do
79
inherit! :search_paths
810

9-
11+
pod 'FBSnapshotTestCase' , '~> 2.1.4'
1012
end
1113
end

0 commit comments

Comments
 (0)