Skip to content

Commit c3e256e

Browse files
committed
Podspec and example project setup
1 parent 64c0efb commit c3e256e

22 files changed

+1139
-0
lines changed

Example/.gitattributes

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.pbxproj binary merge=union

Example/.gitignore

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# OS X Finder
2+
.DS_Store
3+
4+
# Xcode per-user config
5+
*.mode1
6+
*.mode1v3
7+
*.mode2v3
8+
*.perspective
9+
*.perspectivev3
10+
*.pbxuser
11+
xcuserdata
12+
*.xccheckout
13+
# Build products
14+
build/
15+
*.o
16+
*.LinkFileList
17+
*.hmap
18+
# Automatic backup files
19+
*~.nib/
20+
*.swp
21+
*~
22+
*.dat
23+
*.dep
24+
# Cocoapods
25+
Pods
26+
# AppCode specific files
27+
.idea/
28+
*.iml

Example/Example.xcodeproj/project.pbxproj

+618
Large diffs are not rendered by default.

Example/Example.xcodeproj/project.xcworkspace/contents.xcworkspacedata

+7
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Example/Example.xcworkspace/contents.xcworkspacedata

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Example/Example/AppDelegate.h

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
2+
#import <UIKit/UIKit.h>
3+
4+
@interface AppDelegate : UIResponder <UIApplicationDelegate>
5+
6+
@property (strong, nonatomic) UIWindow *window;
7+
8+
@end

Example/Example/AppDelegate.m

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
2+
#import "AppDelegate.h"
3+
4+
@implementation AppDelegate
5+
6+
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
7+
{
8+
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
9+
// Override point for customization after application launch.
10+
self.window.backgroundColor = [UIColor whiteColor];
11+
[self.window makeKeyAndVisible];
12+
return YES;
13+
}
14+
15+
- (void)applicationWillResignActive:(UIApplication *)application
16+
{
17+
// 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.
18+
// 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.
19+
}
20+
21+
- (void)applicationDidEnterBackground:(UIApplication *)application
22+
{
23+
// 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.
24+
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
25+
}
26+
27+
- (void)applicationWillEnterForeground:(UIApplication *)application
28+
{
29+
// Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
30+
}
31+
32+
- (void)applicationDidBecomeActive:(UIApplication *)application
33+
{
34+
// 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.
35+
}
36+
37+
- (void)applicationWillTerminate:(UIApplication *)application
38+
{
39+
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
40+
}
41+
42+
@end

Example/Example/Example-Info.plist

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleDevelopmentRegion</key>
6+
<string>en</string>
7+
<key>CFBundleDisplayName</key>
8+
<string>${PRODUCT_NAME}</string>
9+
<key>CFBundleExecutable</key>
10+
<string>${EXECUTABLE_NAME}</string>
11+
<key>CFBundleIdentifier</key>
12+
<string>com.mokagio.ios.${PRODUCT_NAME:rfc1034identifier}</string>
13+
<key>CFBundleInfoDictionaryVersion</key>
14+
<string>6.0</string>
15+
<key>CFBundleName</key>
16+
<string>${PRODUCT_NAME}</string>
17+
<key>CFBundlePackageType</key>
18+
<string>APPL</string>
19+
<key>CFBundleShortVersionString</key>
20+
<string>1.0</string>
21+
<key>CFBundleSignature</key>
22+
<string>????</string>
23+
<key>CFBundleVersion</key>
24+
<string>1.0</string>
25+
<key>LSRequiresIPhoneOS</key>
26+
<true/>
27+
<key>UIRequiredDeviceCapabilities</key>
28+
<array>
29+
<string>armv7</string>
30+
</array>
31+
<key>UISupportedInterfaceOrientations</key>
32+
<array>
33+
<string>UIInterfaceOrientationPortrait</string>
34+
<string>UIInterfaceOrientationLandscapeLeft</string>
35+
<string>UIInterfaceOrientationLandscapeRight</string>
36+
</array>
37+
<key>UISupportedInterfaceOrientations~ipad</key>
38+
<array>
39+
<string>UIInterfaceOrientationPortrait</string>
40+
<string>UIInterfaceOrientationPortraitUpsideDown</string>
41+
<string>UIInterfaceOrientationLandscapeLeft</string>
42+
<string>UIInterfaceOrientationLandscapeRight</string>
43+
</array>
44+
</dict>
45+
</plist>

Example/Example/Example-Prefix.pch

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
//
2+
// Prefix header
3+
//
4+
// The contents of this file are implicitly included at the beginning of every source file.
5+
//
6+
7+
#import <Availability.h>
8+
9+
#ifndef __IPHONE_3_0
10+
#warning "This project uses features only available in iOS SDK 3.0 and later."
11+
#endif
12+
13+
#ifdef __OBJC__
14+
#import <UIKit/UIKit.h>
15+
#import <Foundation/Foundation.h>
16+
#endif
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2+
#import <UIKit/UIKit.h>
3+
4+
@interface ExampleViewController : UIViewController
5+
6+
@end
+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
2+
#import "ExampleViewController.h"
3+
4+
@interface ExampleViewController ()
5+
6+
@end
7+
8+
@implementation ExampleViewController
9+
10+
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
11+
{
12+
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
13+
if (self) {
14+
// Custom initialization
15+
}
16+
return self;
17+
}
18+
19+
- (void)viewDidLoad
20+
{
21+
[super viewDidLoad];
22+
// Do any additional setup after loading the view from its nib.
23+
}
24+
25+
- (void)didReceiveMemoryWarning
26+
{
27+
[super didReceiveMemoryWarning];
28+
// Dispose of any resources that can be recreated.
29+
}
30+
31+
@end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
{
2+
"images" : [
3+
{
4+
"idiom" : "iphone",
5+
"size" : "29x29",
6+
"scale" : "2x"
7+
},
8+
{
9+
"idiom" : "iphone",
10+
"size" : "40x40",
11+
"scale" : "2x"
12+
},
13+
{
14+
"idiom" : "iphone",
15+
"size" : "60x60",
16+
"scale" : "2x"
17+
},
18+
{
19+
"idiom" : "ipad",
20+
"size" : "29x29",
21+
"scale" : "1x"
22+
},
23+
{
24+
"idiom" : "ipad",
25+
"size" : "29x29",
26+
"scale" : "2x"
27+
},
28+
{
29+
"idiom" : "ipad",
30+
"size" : "40x40",
31+
"scale" : "1x"
32+
},
33+
{
34+
"idiom" : "ipad",
35+
"size" : "40x40",
36+
"scale" : "2x"
37+
},
38+
{
39+
"idiom" : "ipad",
40+
"size" : "76x76",
41+
"scale" : "1x"
42+
},
43+
{
44+
"idiom" : "ipad",
45+
"size" : "76x76",
46+
"scale" : "2x"
47+
}
48+
],
49+
"info" : {
50+
"version" : 1,
51+
"author" : "xcode"
52+
}
53+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
{
2+
"images" : [
3+
{
4+
"orientation" : "portrait",
5+
"idiom" : "iphone",
6+
"extent" : "full-screen",
7+
"minimum-system-version" : "7.0",
8+
"scale" : "2x"
9+
},
10+
{
11+
"orientation" : "portrait",
12+
"idiom" : "iphone",
13+
"subtype" : "retina4",
14+
"extent" : "full-screen",
15+
"minimum-system-version" : "7.0",
16+
"scale" : "2x"
17+
},
18+
{
19+
"orientation" : "portrait",
20+
"idiom" : "ipad",
21+
"extent" : "full-screen",
22+
"minimum-system-version" : "7.0",
23+
"scale" : "1x"
24+
},
25+
{
26+
"orientation" : "landscape",
27+
"idiom" : "ipad",
28+
"extent" : "full-screen",
29+
"minimum-system-version" : "7.0",
30+
"scale" : "1x"
31+
},
32+
{
33+
"orientation" : "portrait",
34+
"idiom" : "ipad",
35+
"extent" : "full-screen",
36+
"minimum-system-version" : "7.0",
37+
"scale" : "2x"
38+
},
39+
{
40+
"orientation" : "landscape",
41+
"idiom" : "ipad",
42+
"extent" : "full-screen",
43+
"minimum-system-version" : "7.0",
44+
"scale" : "2x"
45+
}
46+
],
47+
"info" : {
48+
"version" : 1,
49+
"author" : "xcode"
50+
}
51+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/* Localized versions of Info.plist keys */
2+

Example/Example/main.m

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//
2+
// main.m
3+
// Example
4+
//
5+
// Created by Gio on 21/04/2014.
6+
//
7+
//
8+
9+
#import <UIKit/UIKit.h>
10+
11+
#import "AppDelegate.h"
12+
13+
int main(int argc, char * argv[])
14+
{
15+
@autoreleasepool {
16+
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
17+
}
18+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleDevelopmentRegion</key>
6+
<string>en</string>
7+
<key>CFBundleExecutable</key>
8+
<string>${EXECUTABLE_NAME}</string>
9+
<key>CFBundleIdentifier</key>
10+
<string>com.mokagio.ios.${PRODUCT_NAME:rfc1034identifier}</string>
11+
<key>CFBundleInfoDictionaryVersion</key>
12+
<string>6.0</string>
13+
<key>CFBundlePackageType</key>
14+
<string>BNDL</string>
15+
<key>CFBundleShortVersionString</key>
16+
<string>1.0</string>
17+
<key>CFBundleSignature</key>
18+
<string>????</string>
19+
<key>CFBundleVersion</key>
20+
<string>1</string>
21+
</dict>
22+
</plist>

Example/ExampleTests/ExampleTests.m

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
//
2+
// ExampleTests.m
3+
// ExampleTests
4+
//
5+
// Created by Gio on 21/04/2014.
6+
//
7+
//
8+
9+
#import <XCTest/XCTest.h>
10+
11+
@interface ExampleTests : XCTestCase
12+
13+
@end
14+
15+
@implementation ExampleTests
16+
17+
- (void)setUp
18+
{
19+
[super setUp];
20+
// Put setup code here. This method is called before the invocation of each test method in the class.
21+
}
22+
23+
- (void)tearDown
24+
{
25+
// Put teardown code here. This method is called after the invocation of each test method in the class.
26+
[super tearDown];
27+
}
28+
29+
- (void)testExample
30+
{
31+
XCTFail(@"No implementation for \"%s\"", __PRETTY_FUNCTION__);
32+
}
33+
34+
@end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/* Localized versions of Info.plist keys */
2+

Example/Podfile

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
platform :ios
2+
3+
target :Example do
4+
pod 'UICollectionViewLeftAlignedLayout', :path => '../'
5+
end

0 commit comments

Comments
 (0)