Repository: cordova-ios Updated Branches: refs/heads/master ae2dd0881 -> bab65b994
CB-7187 Delete CDVShared.m & remove dependency on CoreLocation Project: http://git-wip-us.apache.org/repos/asf/cordova-ios/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-ios/commit/bab65b99 Tree: http://git-wip-us.apache.org/repos/asf/cordova-ios/tree/bab65b99 Diff: http://git-wip-us.apache.org/repos/asf/cordova-ios/diff/bab65b99 Branch: refs/heads/master Commit: bab65b994818f04f9a7fd61cd33a6bcb3a2599da Parents: ae2dd08 Author: Andrew Grieve <[email protected]> Authored: Mon Jul 21 22:55:18 2014 -0400 Committer: Andrew Grieve <[email protected]> Committed: Mon Jul 21 22:55:18 2014 -0400 ---------------------------------------------------------------------- CordovaLib/Classes/CDVShared.h | 15 +---- CordovaLib/Classes/CDVShared.m | 59 -------------------- CordovaLib/CordovaLib.xcodeproj/project.pbxproj | 4 -- .../project/__CLI__.xcodeproj/project.pbxproj | 4 -- .../__NON-CLI__.xcodeproj/project.pbxproj | 4 -- 5 files changed, 2 insertions(+), 84 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/bab65b99/CordovaLib/Classes/CDVShared.h ---------------------------------------------------------------------- diff --git a/CordovaLib/Classes/CDVShared.h b/CordovaLib/Classes/CDVShared.h index c54567a..68acc5c 100644 --- a/CordovaLib/Classes/CDVShared.h +++ b/CordovaLib/Classes/CDVShared.h @@ -17,17 +17,6 @@ under the License. */ -#import <Foundation/Foundation.h> +// This file was emptied out in 3.6.0 release (July 2014). +// It will be deleted in a future release. #import <CoreLocation/CoreLocation.h> - -@interface NSError (JSONMethods) - -- (NSString*)JSONRepresentation; - -@end - -@interface CLLocation (JSONMethods) - -- (NSString*)JSONRepresentation; - -@end http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/bab65b99/CordovaLib/Classes/CDVShared.m ---------------------------------------------------------------------- diff --git a/CordovaLib/Classes/CDVShared.m b/CordovaLib/Classes/CDVShared.m deleted file mode 100644 index ac82234..0000000 --- a/CordovaLib/Classes/CDVShared.m +++ /dev/null @@ -1,59 +0,0 @@ -/* - Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. - */ - -#import "CDVShared.h" - -#pragma mark - -#pragma mark CLLocation(JSONMethods) - -@implementation CLLocation (JSONMethods) - -- (NSString*)JSONRepresentation -{ - return [NSString stringWithFormat: - @"{ timestamp: %.00f, \ - coords: { latitude: %f, longitude: %f, altitude: %.02f, heading: %.02f, speed: %.02f, accuracy: %.02f, altitudeAccuracy: %.02f } \ - }", - [self.timestamp timeIntervalSince1970] * 1000.0, - self.coordinate.latitude, - self.coordinate.longitude, - self.altitude, - self.course, - self.speed, - self.horizontalAccuracy, - self.verticalAccuracy - ]; -} - -@end - -#pragma mark NSError(JSONMethods) - -@implementation NSError (JSONMethods) - -- (NSString*)JSONRepresentation -{ - return [NSString stringWithFormat: - @"{ code: %ld, message: '%@'}", - (long)self.code, - [self localizedDescription] - ]; -} - -@end http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/bab65b99/CordovaLib/CordovaLib.xcodeproj/project.pbxproj ---------------------------------------------------------------------- diff --git a/CordovaLib/CordovaLib.xcodeproj/project.pbxproj b/CordovaLib/CordovaLib.xcodeproj/project.pbxproj index a084d16..6e67777 100644 --- a/CordovaLib/CordovaLib.xcodeproj/project.pbxproj +++ b/CordovaLib/CordovaLib.xcodeproj/project.pbxproj @@ -8,7 +8,6 @@ /* Begin PBXBuildFile section */ 1B701028177A61CF00AE11F4 /* CDVShared.h in Headers */ = {isa = PBXBuildFile; fileRef = 1B701026177A61CF00AE11F4 /* CDVShared.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 1B701029177A61CF00AE11F4 /* CDVShared.m in Sources */ = {isa = PBXBuildFile; fileRef = 1B701027177A61CF00AE11F4 /* CDVShared.m */; }; 1F92F4A01314023E0046367C /* CDVPluginResult.h in Headers */ = {isa = PBXBuildFile; fileRef = 1F92F49E1314023E0046367C /* CDVPluginResult.h */; settings = {ATTRIBUTES = (Public, ); }; }; 1F92F4A11314023E0046367C /* CDVPluginResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 1F92F49F1314023E0046367C /* CDVPluginResult.m */; }; 301F2F2A14F3C9CA003FE9FC /* CDV.h in Headers */ = {isa = PBXBuildFile; fileRef = 301F2F2914F3C9CA003FE9FC /* CDV.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -56,7 +55,6 @@ /* Begin PBXFileReference section */ 1B701026177A61CF00AE11F4 /* CDVShared.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CDVShared.h; path = Classes/CDVShared.h; sourceTree = "<group>"; }; - 1B701027177A61CF00AE11F4 /* CDVShared.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CDVShared.m; path = Classes/CDVShared.m; sourceTree = "<group>"; }; 1F92F49E1314023E0046367C /* CDVPluginResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CDVPluginResult.h; path = Classes/CDVPluginResult.h; sourceTree = "<group>"; }; 1F92F49F1314023E0046367C /* CDVPluginResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CDVPluginResult.m; path = Classes/CDVPluginResult.m; sourceTree = "<group>"; }; 301F2F2914F3C9CA003FE9FC /* CDV.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CDV.h; path = Classes/CDV.h; sourceTree = "<group>"; }; @@ -204,7 +202,6 @@ 30C684931407044A004C1A8E /* CDVURLProtocol.m */, 30C6847E1406CB38004C1A8E /* CDVWhitelist.h */, 1B701026177A61CF00AE11F4 /* CDVShared.h */, - 1B701027177A61CF00AE11F4 /* CDVShared.m */, 30C6847F1406CB38004C1A8E /* CDVWhitelist.m */, 30E33AF013A7E24B00594D64 /* CDVPlugin.h */, 30E33AF113A7E24B00594D64 /* CDVPlugin.m */, @@ -359,7 +356,6 @@ EB96673C16A8970A00D86CDF /* CDVUserAgentUtil.m in Sources */, EBFF4DBC16D3FE2E008F452B /* CDVWebViewDelegate.m in Sources */, 7E14B5A91705050A0032169E /* CDVTimer.m in Sources */, - 1B701029177A61CF00AE11F4 /* CDVShared.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/bab65b99/bin/templates/project/__CLI__.xcodeproj/project.pbxproj ---------------------------------------------------------------------- diff --git a/bin/templates/project/__CLI__.xcodeproj/project.pbxproj b/bin/templates/project/__CLI__.xcodeproj/project.pbxproj index 4fc1058..cf949d0 100755 --- a/bin/templates/project/__CLI__.xcodeproj/project.pbxproj +++ b/bin/templates/project/__CLI__.xcodeproj/project.pbxproj @@ -26,7 +26,6 @@ 308D05391370CCF300D202BF /* [email protected] in Resources */ = {isa = PBXBuildFile; fileRef = 308D05301370CCF300D202BF /* [email protected] */; }; 30A0434814DC770100060A13 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 30A0434314DC770100060A13 /* Localizable.strings */; }; 30FC414916E50CA1004E6F35 /* [email protected] in Resources */ = {isa = PBXBuildFile; fileRef = 30FC414816E50CA1004E6F35 /* [email protected] */; }; - 5AEE5B35173C68D80009041E /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5AEE5B34173C68D80009041E /* CoreLocation.framework */; }; 5B1594DD16A7569C00FEF299 /* AssetsLibrary.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5B1594DC16A7569C00FEF299 /* AssetsLibrary.framework */; }; 7E7966DE1810823500FA85AD /* icon-40.png in Resources */ = {isa = PBXBuildFile; fileRef = 7E7966D41810823500FA85AD /* icon-40.png */; }; 7E7966DF1810823500FA85AD /* [email protected] in Resources */ = {isa = PBXBuildFile; fileRef = 7E7966D51810823500FA85AD /* [email protected] */; }; @@ -85,7 +84,6 @@ 30A0434714DC770100060A13 /* se */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = se; path = Localizable.strings; sourceTree = "<group>"; }; 30FC414816E50CA1004E6F35 /* [email protected] */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "[email protected]"; sourceTree = "<group>"; }; 32CA4F630368D1EE00C91783 /* __PROJECT_NAME__-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "__PROJECT_NAME__-Prefix.pch"; sourceTree = "<group>"; }; - 5AEE5B34173C68D80009041E /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; }; 5B1594DC16A7569C00FEF299 /* AssetsLibrary.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AssetsLibrary.framework; path = System/Library/Frameworks/AssetsLibrary.framework; sourceTree = SDKROOT; }; 7E7966D41810823500FA85AD /* icon-40.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon-40.png"; sourceTree = "<group>"; }; 7E7966D51810823500FA85AD /* [email protected] */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "[email protected]"; sourceTree = "<group>"; }; @@ -114,7 +112,6 @@ 301BF552109A68D80062928A /* libCordova.a in Frameworks */, 288765FD0DF74451002DB57D /* CoreGraphics.framework in Frameworks */, 305D5FD1115AB8F900A74A75 /* MobileCoreServices.framework in Frameworks */, - 5AEE5B35173C68D80009041E /* CoreLocation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -204,7 +201,6 @@ 29B97323FDCFA39411CA2CEA /* Frameworks */ = { isa = PBXGroup; children = ( - 5AEE5B34173C68D80009041E /* CoreLocation.framework */, 5B1594DC16A7569C00FEF299 /* AssetsLibrary.framework */, 288765FC0DF74451002DB57D /* CoreGraphics.framework */, 305D5FD0115AB8F900A74A75 /* MobileCoreServices.framework */, http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/bab65b99/bin/templates/project/__NON-CLI__.xcodeproj/project.pbxproj ---------------------------------------------------------------------- diff --git a/bin/templates/project/__NON-CLI__.xcodeproj/project.pbxproj b/bin/templates/project/__NON-CLI__.xcodeproj/project.pbxproj index a59b3bd..afc446c 100755 --- a/bin/templates/project/__NON-CLI__.xcodeproj/project.pbxproj +++ b/bin/templates/project/__NON-CLI__.xcodeproj/project.pbxproj @@ -26,7 +26,6 @@ 308D05391370CCF300D202BF /* [email protected] in Resources */ = {isa = PBXBuildFile; fileRef = 308D05301370CCF300D202BF /* [email protected] */; }; 30A0434814DC770100060A13 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 30A0434314DC770100060A13 /* Localizable.strings */; }; 30FC414916E50CA1004E6F35 /* [email protected] in Resources */ = {isa = PBXBuildFile; fileRef = 30FC414816E50CA1004E6F35 /* [email protected] */; }; - 5AEE5B35173C68D80009041E /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5AEE5B34173C68D80009041E /* CoreLocation.framework */; }; 5B1594DD16A7569C00FEF299 /* AssetsLibrary.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5B1594DC16A7569C00FEF299 /* AssetsLibrary.framework */; }; 7E7966DE1810823500FA85AD /* icon-40.png in Resources */ = {isa = PBXBuildFile; fileRef = 7E7966D41810823500FA85AD /* icon-40.png */; }; 7E7966DF1810823500FA85AD /* [email protected] in Resources */ = {isa = PBXBuildFile; fileRef = 7E7966D51810823500FA85AD /* [email protected] */; }; @@ -85,7 +84,6 @@ 30A0434714DC770100060A13 /* se */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = se; path = Localizable.strings; sourceTree = "<group>"; }; 30FC414816E50CA1004E6F35 /* [email protected] */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "[email protected]"; sourceTree = "<group>"; }; 32CA4F630368D1EE00C91783 /* __PROJECT_NAME__-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "__PROJECT_NAME__-Prefix.pch"; sourceTree = "<group>"; }; - 5AEE5B34173C68D80009041E /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; }; 5B1594DC16A7569C00FEF299 /* AssetsLibrary.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AssetsLibrary.framework; path = System/Library/Frameworks/AssetsLibrary.framework; sourceTree = SDKROOT; }; 7E7966D41810823500FA85AD /* icon-40.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon-40.png"; sourceTree = "<group>"; }; 7E7966D51810823500FA85AD /* [email protected] */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "[email protected]"; sourceTree = "<group>"; }; @@ -111,7 +109,6 @@ 301BF552109A68D80062928A /* libCordova.a in Frameworks */, 288765FD0DF74451002DB57D /* CoreGraphics.framework in Frameworks */, 305D5FD1115AB8F900A74A75 /* MobileCoreServices.framework in Frameworks */, - 5AEE5B35173C68D80009041E /* CoreLocation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -199,7 +196,6 @@ 29B97323FDCFA39411CA2CEA /* Frameworks */ = { isa = PBXGroup; children = ( - 5AEE5B34173C68D80009041E /* CoreLocation.framework */, 5B1594DC16A7569C00FEF299 /* AssetsLibrary.framework */, 288765FC0DF74451002DB57D /* CoreGraphics.framework */, 305D5FD0115AB8F900A74A75 /* MobileCoreServices.framework */,
