forked from robovm/apple-ios-samples
-
Notifications
You must be signed in to change notification settings - Fork 204
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7,678 changed files
with
616,313 additions
and
0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>CFBundleDevelopmentRegion</key> | ||
<string>English</string> | ||
<key>CFBundleDisplayName</key> | ||
<string>${PRODUCT_NAME}</string> | ||
<key>CFBundleExecutable</key> | ||
<string>${EXECUTABLE_NAME}</string> | ||
<key>CFBundleIconFiles</key> | ||
<array> | ||
<string>Icon.png</string> | ||
<string>[email protected]</string> | ||
<string>Icon-72.png</string> | ||
<string>Icon-Small.png</string> | ||
<string>Icon-Small-50.png</string> | ||
<string>[email protected]</string> | ||
</array> | ||
<key>CFBundleIdentifier</key> | ||
<string>com.example.apple-samplecode.${PRODUCT_NAME:rfc1034identifier}</string> | ||
<key>CFBundleInfoDictionaryVersion</key> | ||
<string>6.0</string> | ||
<key>CFBundleName</key> | ||
<string>${PRODUCT_NAME}</string> | ||
<key>CFBundlePackageType</key> | ||
<string>APPL</string> | ||
<key>CFBundleShortVersionString</key> | ||
<string>1.1</string> | ||
<key>CFBundleSignature</key> | ||
<string>????</string> | ||
<key>CFBundleVersion</key> | ||
<string>1.1</string> | ||
<key>LSRequiresIPhoneOS</key> | ||
<true/> | ||
<key>UIMainStoryboardFile</key> | ||
<string>Storyboard</string> | ||
<key>UISupportedInterfaceOrientations</key> | ||
<array> | ||
<string>UIInterfaceOrientationPortrait</string> | ||
<string>UIInterfaceOrientationLandscapeLeft</string> | ||
<string>UIInterfaceOrientationLandscapeRight</string> | ||
</array> | ||
</dict> | ||
</plist> |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// Prefix header for all source files of the 'ABUIGroup' target in the 'ABUIGroup' project | ||
// | ||
#import <Availability.h> | ||
|
||
#ifndef __IPHONE_6_0 | ||
#warning "This project uses features only available in iOS SDK 6.0 and later." | ||
#endif | ||
|
||
|
||
#ifdef __OBJC__ | ||
#import <Foundation/Foundation.h> | ||
#import <UIKit/UIKit.h> | ||
#import <AddressBook/AddressBook.h> | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
/* | ||
File: ABUIGroupsAppDelegate.h | ||
Abstract: Application delegate that sets up the application. | ||
Version: 1.1 | ||
Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple | ||
Inc. ("Apple") in consideration of your agreement to the following | ||
terms, and your use, installation, modification or redistribution of | ||
this Apple software constitutes acceptance of these terms. If you do | ||
not agree with these terms, please do not use, install, modify or | ||
redistribute this Apple software. | ||
In consideration of your agreement to abide by the following terms, and | ||
subject to these terms, Apple grants you a personal, non-exclusive | ||
license, under Apple's copyrights in this original Apple software (the | ||
"Apple Software"), to use, reproduce, modify and redistribute the Apple | ||
Software, with or without modifications, in source and/or binary forms; | ||
provided that if you redistribute the Apple Software in its entirety and | ||
without modifications, you must retain this notice and the following | ||
text and disclaimers in all such redistributions of the Apple Software. | ||
Neither the name, trademarks, service marks or logos of Apple Inc. may | ||
be used to endorse or promote products derived from the Apple Software | ||
without specific prior written permission from Apple. Except as | ||
expressly stated in this notice, no other rights or licenses, express or | ||
implied, are granted by Apple herein, including but not limited to any | ||
patent rights that may be infringed by your derivative works or by other | ||
works in which the Apple Software may be incorporated. | ||
The Apple Software is provided by Apple on an "AS IS" basis. APPLE | ||
MAKES NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION | ||
THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS | ||
FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND | ||
OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS. | ||
IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL | ||
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION, | ||
MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED | ||
AND WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), | ||
STRICT LIABILITY OR OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE | ||
POSSIBILITY OF SUCH DAMAGE. | ||
Copyright (C) 2013 Apple Inc. All Rights Reserved. | ||
*/ | ||
|
||
@interface ABUIGroupsAppDelegate : UIResponder <UIApplicationDelegate> | ||
@property (strong, nonatomic) UIWindow *window; | ||
|
||
@end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
/* | ||
File: ABUIGroupsAppDelegate.m | ||
Abstract: Application delegate that sets up the application. | ||
Version: 1.1 | ||
Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple | ||
Inc. ("Apple") in consideration of your agreement to the following | ||
terms, and your use, installation, modification or redistribution of | ||
this Apple software constitutes acceptance of these terms. If you do | ||
not agree with these terms, please do not use, install, modify or | ||
redistribute this Apple software. | ||
In consideration of your agreement to abide by the following terms, and | ||
subject to these terms, Apple grants you a personal, non-exclusive | ||
license, under Apple's copyrights in this original Apple software (the | ||
"Apple Software"), to use, reproduce, modify and redistribute the Apple | ||
Software, with or without modifications, in source and/or binary forms; | ||
provided that if you redistribute the Apple Software in its entirety and | ||
without modifications, you must retain this notice and the following | ||
text and disclaimers in all such redistributions of the Apple Software. | ||
Neither the name, trademarks, service marks or logos of Apple Inc. may | ||
be used to endorse or promote products derived from the Apple Software | ||
without specific prior written permission from Apple. Except as | ||
expressly stated in this notice, no other rights or licenses, express or | ||
implied, are granted by Apple herein, including but not limited to any | ||
patent rights that may be infringed by your derivative works or by other | ||
works in which the Apple Software may be incorporated. | ||
The Apple Software is provided by Apple on an "AS IS" basis. APPLE | ||
MAKES NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION | ||
THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS | ||
FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND | ||
OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS. | ||
IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL | ||
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION, | ||
MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED | ||
AND WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), | ||
STRICT LIABILITY OR OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE | ||
POSSIBILITY OF SUCH DAMAGE. | ||
Copyright (C) 2013 Apple Inc. All Rights Reserved. | ||
*/ | ||
|
||
#import "ABUIGroupsAppDelegate.h" | ||
|
||
@implementation ABUIGroupsAppDelegate | ||
|
||
#pragma mark - | ||
#pragma mark Application lifecycle | ||
|
||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions | ||
{ | ||
return YES; | ||
} | ||
|
||
|
||
- (void)applicationWillResignActive:(UIApplication *)application | ||
{ | ||
/* | ||
Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. | ||
Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. | ||
*/ | ||
} | ||
|
||
|
||
- (void)applicationDidEnterBackground:(UIApplication *)application | ||
{ | ||
/* | ||
Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. | ||
If your application supports background execution, called instead of applicationWillTerminate: when the user quits. | ||
*/ | ||
} | ||
|
||
|
||
- (void)applicationWillEnterForeground:(UIApplication *)application | ||
{ | ||
/* | ||
Called as part of transition from the background to the inactive state: here you can undo many of the changes made on entering the background. | ||
*/ | ||
} | ||
|
||
|
||
- (void)applicationDidBecomeActive:(UIApplication *)application | ||
{ | ||
/* | ||
Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. | ||
*/ | ||
} | ||
|
||
|
||
- (void)applicationWillTerminate:(UIApplication *)application | ||
{ | ||
/* | ||
Called when the application is about to terminate. | ||
See also applicationDidEnterBackground:. | ||
*/ | ||
} | ||
|
||
|
||
#pragma mark - | ||
#pragma mark Memory management | ||
|
||
- (void)applicationDidReceiveMemoryWarning:(UIApplication *)application | ||
{ | ||
/* | ||
Free up as much memory as possible by purging cached data objects that can be recreated (or reloaded from disk) later. | ||
*/ | ||
} | ||
|
||
@end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
/* | ||
File: AddGroupViewController.h | ||
Abstract: Allows users to enter a name for a new group. | ||
Version: 1.1 | ||
Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple | ||
Inc. ("Apple") in consideration of your agreement to the following | ||
terms, and your use, installation, modification or redistribution of | ||
this Apple software constitutes acceptance of these terms. If you do | ||
not agree with these terms, please do not use, install, modify or | ||
redistribute this Apple software. | ||
In consideration of your agreement to abide by the following terms, and | ||
subject to these terms, Apple grants you a personal, non-exclusive | ||
license, under Apple's copyrights in this original Apple software (the | ||
"Apple Software"), to use, reproduce, modify and redistribute the Apple | ||
Software, with or without modifications, in source and/or binary forms; | ||
provided that if you redistribute the Apple Software in its entirety and | ||
without modifications, you must retain this notice and the following | ||
text and disclaimers in all such redistributions of the Apple Software. | ||
Neither the name, trademarks, service marks or logos of Apple Inc. may | ||
be used to endorse or promote products derived from the Apple Software | ||
without specific prior written permission from Apple. Except as | ||
expressly stated in this notice, no other rights or licenses, express or | ||
implied, are granted by Apple herein, including but not limited to any | ||
patent rights that may be infringed by your derivative works or by other | ||
works in which the Apple Software may be incorporated. | ||
The Apple Software is provided by Apple on an "AS IS" basis. APPLE | ||
MAKES NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION | ||
THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS | ||
FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND | ||
OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS. | ||
IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL | ||
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION, | ||
MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED | ||
AND WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), | ||
STRICT LIABILITY OR OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE | ||
POSSIBILITY OF SUCH DAMAGE. | ||
Copyright (C) 2013 Apple Inc. All Rights Reserved. | ||
*/ | ||
|
||
@interface AddGroupViewController : UIViewController | ||
@property (nonatomic, copy) NSString *group; | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
/* | ||
File: AddGroupViewController.m | ||
Abstract: Allows users to enter a name for a new group. | ||
Version: 1.1 | ||
Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple | ||
Inc. ("Apple") in consideration of your agreement to the following | ||
terms, and your use, installation, modification or redistribution of | ||
this Apple software constitutes acceptance of these terms. If you do | ||
not agree with these terms, please do not use, install, modify or | ||
redistribute this Apple software. | ||
In consideration of your agreement to abide by the following terms, and | ||
subject to these terms, Apple grants you a personal, non-exclusive | ||
license, under Apple's copyrights in this original Apple software (the | ||
"Apple Software"), to use, reproduce, modify and redistribute the Apple | ||
Software, with or without modifications, in source and/or binary forms; | ||
provided that if you redistribute the Apple Software in its entirety and | ||
without modifications, you must retain this notice and the following | ||
text and disclaimers in all such redistributions of the Apple Software. | ||
Neither the name, trademarks, service marks or logos of Apple Inc. may | ||
be used to endorse or promote products derived from the Apple Software | ||
without specific prior written permission from Apple. Except as | ||
expressly stated in this notice, no other rights or licenses, express or | ||
implied, are granted by Apple herein, including but not limited to any | ||
patent rights that may be infringed by your derivative works or by other | ||
works in which the Apple Software may be incorporated. | ||
The Apple Software is provided by Apple on an "AS IS" basis. APPLE | ||
MAKES NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION | ||
THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS | ||
FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND | ||
OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS. | ||
IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL | ||
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION, | ||
MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED | ||
AND WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), | ||
STRICT LIABILITY OR OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE | ||
POSSIBILITY OF SUCH DAMAGE. | ||
Copyright (C) 2013 Apple Inc. All Rights Reserved. | ||
*/ | ||
|
||
#import "AddGroupViewController.h" | ||
|
||
@interface AddGroupViewController () <UITextFieldDelegate> | ||
@property (weak, nonatomic) IBOutlet UITextField *myTextField; | ||
|
||
@end | ||
|
||
|
||
@implementation AddGroupViewController | ||
|
||
- (BOOL)textFieldShouldReturn:(UITextField *)textField | ||
{ | ||
// When the user presses return, take focus away from the text field so | ||
// that the keyboard is dismissed. | ||
if (textField == self.myTextField) | ||
{ | ||
[textField resignFirstResponder]; | ||
} | ||
return YES; | ||
} | ||
|
||
|
||
// Used to send back the user's input to GroupViewController | ||
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender | ||
{ | ||
if ([[segue identifier] isEqualToString:@"returnInput"]) | ||
{ | ||
if ([self.myTextField.text length] > 0) | ||
{ | ||
self.group = self.myTextField.text; | ||
} | ||
} | ||
} | ||
|
||
|
||
#pragma mark - | ||
#pragma mark Memory management | ||
|
||
- (void)didReceiveMemoryWarning | ||
{ | ||
// Release the view if it doesn't have a superview. | ||
[super didReceiveMemoryWarning]; | ||
} | ||
|
||
@end |
Oops, something went wrong.