Skip to content
Browse files

All Classes now compile on iOS or have been excluded from the project

the following classes now compile on iOS
-NSURLConnectionAdditions
-CWDebugUtilities
-CWPathUtilities
-CWMD5Utilities
-CWCoreDataCenter
-NSManagedObjectAdditions
-CWExceptionUtilities
-CWReachability
-NSDateAdditions
-NSOperationQueueAdditions
-NSManagedObjectContextAdditions
still a lot of work to do
  • Loading branch information...
1 parent 89feeb2 commit aecc189532e4f1ddc11dc360b89a0b0aaa046f64 @Machx committed Jan 16, 2012
View
2 Source/CWCoreDataCenter.m
@@ -41,9 +41,11 @@ +(CWCoreDataCenter *)defaultCenter {
dispatch_once(&pred, ^{
center = [[CWCoreDataCenter alloc] init];
+#if !(TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
[center setManagedObjectModel:[[NSApp delegate] managedObjectModel]];
[center setManagedObjectContext:[[NSApp delegate] managedObjectContext]];
[center setPersistentStoreCoordinator:[[NSApp delegate] persistentStoreCoordinator]];
+#endif
});
return center;
View
8 Source/CWExceptionUtilities.h
@@ -28,13 +28,13 @@
*/
-#if TARGET_OS_IPHONE
-#import <Foundation/Foundation.h>
-#elif TARGET_OS_MAC
+#if !(TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
#import <Cocoa/Cocoa.h>
+#else
+#import <Foundation/Foundation.h>
#endif
-#if TARGET_OS_MAC
+#if !(TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
void CWShowExceptionAsAlertPanel(NSException *exception);
#endif
View
2 Source/CWExceptionUtilities.m
@@ -29,6 +29,7 @@ of this software and associated documentation files (the "Software"), to deal
#import "CWExceptionUtilities.h"
+#if !(TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
/**
Takes a NSException object and runs an Critical Alert Panel with the Exception
information as well as the stack trace of where the stack trace occurred minus
@@ -42,6 +43,7 @@ void CWShowExceptionAsAlertPanel(NSException *exception) {
[[NSApplication sharedApplication] terminate:nil];
}
}
+#endif
@implementation NSException (CWNSExceptionAdditions)
View
6 Source/NSManagedObjectContextAdditions.m
@@ -72,13 +72,13 @@ -(void)cw_logObjectsInContext {
if ([self hasChanges]) {
if ([[self insertedObjects] count] > 0) {
- NSLog(@"%ld Inserted Objects",[[self insertedObjects] count]);
+ NSLog(@"%lu Inserted Objects",(long)[[self insertedObjects] count]);
}
if ([[self updatedObjects] count] > 0) {
- NSLog(@"%ld Updated Objects",[[self updatedObjects] count]);
+ NSLog(@"%lu Updated Objects",(long)[[self updatedObjects] count]);
}
if ([[self deletedObjects] count] > 0) {
- NSLog(@"%ld Deleted Objects",[[self deletedObjects] count]);
+ NSLog(@"%lu Deleted Objects",(long)[[self deletedObjects] count]);
}
}
}
View
30 Source/ZangetsuTouch.h
@@ -33,37 +33,37 @@
#import "NSStringAdditions.h"
#import "NSArrayAdditions.h"
#import "NSDictionaryAdditions.h"
-//#import "CWSystemInfo.h"
#import "NSSetAdditions.h"
-//#import "NSURLConnectionAdditions.h"
-//#import "CWDebugUtilities.h"
+#import "NSURLConnectionAdditions.h"
+#import "CWDebugUtilities.h"
#import "NSObjectAdditions.h"
#import "CWFoundation.h"
-//#import "CWPathUtilities.h"
+#import "CWPathUtilities.h"
#import "CWErrorUtilities.h"
#import "CWGraphicsFoundation.h"
-//#import "CWMD5Utilities.h"
+#import "CWMD5Utilities.h"
#import "NSDataAdditions.h"
-//#import "CWCoreDataCenter.h"
-//#import "NSManagedObjectAdditions.h"
-//#import "CWExceptionUtilities.h"
+#import "CWCoreDataCenter.h"
+#import "NSManagedObjectAdditions.h"
+#import "CWExceptionUtilities.h"
#import "CWURLUtilities.h" //IN_PROGRESS_IOS (base64 imp)
#import "CWRuntimeUtilities.h"
-//#import "CWReachability.h"
-//#import "NSDateAddtions.h"
+#import "CWReachability.h"
+#import "NSDateAddtions.h"
#import "CWCFConversionMacros.h"
#import "CWStack.h"
#import "CWTree.h"
#import "CWBTree.h"
#import "NSMutableArrayAdditions.h"
-//#import "CWBase64.h"
-//#import "CWZLib.h"
-//#import "NSOperationQueueAdditions.h"
+#import "NSOperationQueueAdditions.h"
#import "CWQueue.h"
#import "CWURLRequest.h"
-//#import "NSMutableURLRequestAdditions.h"
#import "NSRecursiveLockAdditions.h"
-//#import "NSManagedObjectContextAdditions.h"
+#import "NSManagedObjectContextAdditions.h"
// NO_COMPILE_IOS
//#import "CWTask.h" // NO_NSTASK_IOS
//#import "CWApplicationRegistry.h" //NO_NSWORKSPACE_IOS
+//#import "CWSystemInfo.h" //will need to write a iOS specific version
+//#import "CWBase64.h" //uses sectransform which doesn't exist on iOS (need iOS specific version)
+//#import "CWZLib.h" //uses sectransform which doesn't exist on iOS (need iOS specific version)
+//#import "NSMutableURLRequestAdditions.h" //only 1 api and it uses base 64 encoding in CWBase64
View
40 Zangetsu.xcodeproj/project.pbxproj
@@ -140,6 +140,26 @@
B8C5B95514C48E0F000E0A88 /* CWURLUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = B81BFF8B1305A7F2001A4BCF /* CWURLUtilities.m */; };
B8C5B95614C48E3F000E0A88 /* CWDateUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = B84995C5128396E1001206E1 /* CWDateUtilities.m */; };
B8C5B95714C48E43000E0A88 /* CWDateUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = B84995C4128396E1001206E1 /* CWDateUtilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B95A14C490D7000E0A88 /* NSURLConnectionAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B82D263012ADD557006650B8 /* NSURLConnectionAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B95B14C490DD000E0A88 /* NSURLConnectionAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B82D263112ADD557006650B8 /* NSURLConnectionAdditions.m */; };
+ B8C5B95C14C49108000E0A88 /* CWDebugUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = B8806A6712B3E88500F85BCE /* CWDebugUtilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B95D14C4910E000E0A88 /* CWDebugUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = B8806A6812B3E88500F85BCE /* CWDebugUtilities.m */; };
+ B8C5B95E14C4912A000E0A88 /* CWPathUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = B8E914C812BFF5C000167AE8 /* CWPathUtilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B95F14C49130000E0A88 /* CWPathUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = B8E914C912BFF5C000167AE8 /* CWPathUtilities.m */; };
+ B8C5B96014C49196000E0A88 /* CWMD5Utilities.m in Sources */ = {isa = PBXBuildFile; fileRef = B849523012CBE1CF00098684 /* CWMD5Utilities.m */; };
+ B8C5B96114C49199000E0A88 /* CWMD5Utilities.h in Headers */ = {isa = PBXBuildFile; fileRef = B849522F12CBE1CF00098684 /* CWMD5Utilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96214C491E0000E0A88 /* CWCoreDataCenter.h in Headers */ = {isa = PBXBuildFile; fileRef = B804019712F08E9200E1297F /* CWCoreDataCenter.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96314C491E7000E0A88 /* CWCoreDataCenter.m in Sources */ = {isa = PBXBuildFile; fileRef = B804019812F08E9200E1297F /* CWCoreDataCenter.m */; };
+ B8C5B96414C49254000E0A88 /* NSManagedObjectAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B8E8F62012F1ED15001A0BBF /* NSManagedObjectAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96514C49259000E0A88 /* NSManagedObjectAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B8E8F62112F1ED15001A0BBF /* NSManagedObjectAdditions.m */; };
+ B8C5B96614C492B9000E0A88 /* CWExceptionUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = B8A084CE12F4BA2000EAFCBF /* CWExceptionUtilities.m */; };
+ B8C5B96714C492C1000E0A88 /* CWExceptionUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = B8A084CD12F4BA2000EAFCBF /* CWExceptionUtilities.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96814C492F8000E0A88 /* CWReachability.h in Headers */ = {isa = PBXBuildFile; fileRef = B8D91938133E3C9D009AC4AC /* CWReachability.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96914C492FD000E0A88 /* CWReachability.m in Sources */ = {isa = PBXBuildFile; fileRef = B8D91939133E3C9D009AC4AC /* CWReachability.m */; };
+ B8C5B96A14C493BD000E0A88 /* NSOperationQueueAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B8B77E061436065800CB3F93 /* NSOperationQueueAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96B14C493C2000E0A88 /* NSOperationQueueAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B8B77E071436065900CB3F93 /* NSOperationQueueAdditions.m */; };
+ B8C5B96C14C49432000E0A88 /* NSManagedObjectContextAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B86686A014A37B4400F8A541 /* NSManagedObjectContextAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ B8C5B96D14C49438000E0A88 /* NSManagedObjectContextAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B86686A114A37B4400F8A541 /* NSManagedObjectContextAdditions.m */; };
B8D1F36413AA54630099BBDC /* CWDateUtilitiesTests.m in Sources */ = {isa = PBXBuildFile; fileRef = B8D1F36313AA54630099BBDC /* CWDateUtilitiesTests.m */; };
B8D9193A133E3C9D009AC4AC /* CWReachability.h in Headers */ = {isa = PBXBuildFile; fileRef = B8D91938133E3C9D009AC4AC /* CWReachability.h */; settings = {ATTRIBUTES = (Public, ); }; };
B8D9193B133E3C9D009AC4AC /* CWReachability.m in Sources */ = {isa = PBXBuildFile; fileRef = B8D91939133E3C9D009AC4AC /* CWReachability.m */; };
@@ -758,6 +778,16 @@
B8C5B95014C486E0000E0A88 /* NSSetAdditions.h in Headers */,
B8C5B95414C48E09000E0A88 /* CWURLUtilities.h in Headers */,
B8C5B95714C48E43000E0A88 /* CWDateUtilities.h in Headers */,
+ B8C5B95A14C490D7000E0A88 /* NSURLConnectionAdditions.h in Headers */,
+ B8C5B95C14C49108000E0A88 /* CWDebugUtilities.h in Headers */,
+ B8C5B95E14C4912A000E0A88 /* CWPathUtilities.h in Headers */,
+ B8C5B96114C49199000E0A88 /* CWMD5Utilities.h in Headers */,
+ B8C5B96214C491E0000E0A88 /* CWCoreDataCenter.h in Headers */,
+ B8C5B96414C49254000E0A88 /* NSManagedObjectAdditions.h in Headers */,
+ B8C5B96714C492C1000E0A88 /* CWExceptionUtilities.h in Headers */,
+ B8C5B96814C492F8000E0A88 /* CWReachability.h in Headers */,
+ B8C5B96A14C493BD000E0A88 /* NSOperationQueueAdditions.h in Headers */,
+ B8C5B96C14C49432000E0A88 /* NSManagedObjectContextAdditions.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -995,6 +1025,16 @@
B8C5B95114C486E5000E0A88 /* NSSetAdditions.m in Sources */,
B8C5B95514C48E0F000E0A88 /* CWURLUtilities.m in Sources */,
B8C5B95614C48E3F000E0A88 /* CWDateUtilities.m in Sources */,
+ B8C5B95B14C490DD000E0A88 /* NSURLConnectionAdditions.m in Sources */,
+ B8C5B95D14C4910E000E0A88 /* CWDebugUtilities.m in Sources */,
+ B8C5B95F14C49130000E0A88 /* CWPathUtilities.m in Sources */,
+ B8C5B96014C49196000E0A88 /* CWMD5Utilities.m in Sources */,
+ B8C5B96314C491E7000E0A88 /* CWCoreDataCenter.m in Sources */,
+ B8C5B96514C49259000E0A88 /* NSManagedObjectAdditions.m in Sources */,
+ B8C5B96614C492B9000E0A88 /* CWExceptionUtilities.m in Sources */,
+ B8C5B96914C492FD000E0A88 /* CWReachability.m in Sources */,
+ B8C5B96B14C493C2000E0A88 /* NSOperationQueueAdditions.m in Sources */,
+ B8C5B96D14C49438000E0A88 /* NSManagedObjectContextAdditions.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};

0 comments on commit aecc189

Please sign in to comment.
Something went wrong with that request. Please try again.