├── PinterestLayout
├── pin1.jpg
├── pin2.jpg
├── pin3.jpg
├── pin4.jpg
├── pin5.jpg
├── CollectionViewCell.swift
├── ViewController.swift
├── Images.xcassets
│ └── AppIcon.appiconset
│ │ └── Contents.json
├── DetailViewController.swift
├── Info.plist
├── AppDelegate.swift
├── LayoutController.swift
└── Base.lproj
│ ├── LaunchScreen.xib
│ └── Main.storyboard
├── PinterestLayout.xcodeproj
├── project.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── PinterestLayout.xccheckout
├── xcuserdata
│ └── shrikar.xcuserdatad
│ │ ├── xcschemes
│ │ ├── xcschememanagement.plist
│ │ └── PinterestLayout.xcscheme
│ │ └── xcdebugger
│ │ └── Breakpoints_v2.xcbkptlist
└── project.pbxproj
├── README.md
└── PinterestLayoutTests
├── Info.plist
└── PinterestLayoutTests.swift
/PinterestLayout/pin1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sarchak/UICollectionView/HEAD/PinterestLayout/pin1.jpg
--------------------------------------------------------------------------------
/PinterestLayout/pin2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sarchak/UICollectionView/HEAD/PinterestLayout/pin2.jpg
--------------------------------------------------------------------------------
/PinterestLayout/pin3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sarchak/UICollectionView/HEAD/PinterestLayout/pin3.jpg
--------------------------------------------------------------------------------
/PinterestLayout/pin4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sarchak/UICollectionView/HEAD/PinterestLayout/pin4.jpg
--------------------------------------------------------------------------------
/PinterestLayout/pin5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sarchak/UICollectionView/HEAD/PinterestLayout/pin5.jpg
--------------------------------------------------------------------------------
/PinterestLayout.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | UICollectionView
2 | ================
3 |
4 | A simple pinterest like layout using UICollectionView and UICollectionViewFlow Layout
5 | For more information goto [UICollectionView Flow Layout](http://shrikar.com/blog/2014/12/21/ios-swift-tutorial-uicollectionview-pinterest-layout/)
6 |
--------------------------------------------------------------------------------
/PinterestLayout/CollectionViewCell.swift:
--------------------------------------------------------------------------------
1 | //
2 | // CollectionViewCell.swift
3 | // PinterestLayout
4 | //
5 | // Created by Shrikar Archak on 12/21/14.
6 | // Copyright (c) 2014 Shrikar Archak. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | class CollectionViewCell: UICollectionViewCell {
12 | @IBOutlet weak var title: UILabel!
13 | @IBOutlet weak var pinImage: UIImageView!
14 | }
15 |
--------------------------------------------------------------------------------
/PinterestLayout/ViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.swift
3 | // PinterestLayout
4 | //
5 | // Created by Shrikar Archak on 12/21/14.
6 | // Copyright (c) 2014 Shrikar Archak. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | class ViewController: UIViewController {
12 |
13 | override func viewDidLoad() {
14 | super.viewDidLoad()
15 | // Do any additional setup after loading the view, typically from a nib.
16 | }
17 |
18 | override func didReceiveMemoryWarning() {
19 | super.didReceiveMemoryWarning()
20 | // Dispose of any resources that can be recreated.
21 | }
22 |
23 |
24 | }
25 |
26 |
--------------------------------------------------------------------------------
/PinterestLayout.xcodeproj/xcuserdata/shrikar.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | PinterestLayout.xcscheme
8 |
9 | orderHint
10 | 0
11 |
12 |
13 | SuppressBuildableAutocreation
14 |
15 | 56144E9C1A474E6F00AABFD3
16 |
17 | primary
18 |
19 |
20 | 56144EB11A474E6F00AABFD3
21 |
22 | primary
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/PinterestLayout/Images.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "size" : "29x29",
6 | "scale" : "2x"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "size" : "29x29",
11 | "scale" : "3x"
12 | },
13 | {
14 | "idiom" : "iphone",
15 | "size" : "40x40",
16 | "scale" : "2x"
17 | },
18 | {
19 | "idiom" : "iphone",
20 | "size" : "40x40",
21 | "scale" : "3x"
22 | },
23 | {
24 | "idiom" : "iphone",
25 | "size" : "60x60",
26 | "scale" : "2x"
27 | },
28 | {
29 | "idiom" : "iphone",
30 | "size" : "60x60",
31 | "scale" : "3x"
32 | }
33 | ],
34 | "info" : {
35 | "version" : 1,
36 | "author" : "xcode"
37 | }
38 | }
--------------------------------------------------------------------------------
/PinterestLayoutTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | com.shrikar.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/PinterestLayout.xcodeproj/xcuserdata/shrikar.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
8 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/PinterestLayoutTests/PinterestLayoutTests.swift:
--------------------------------------------------------------------------------
1 | //
2 | // PinterestLayoutTests.swift
3 | // PinterestLayoutTests
4 | //
5 | // Created by Shrikar Archak on 12/21/14.
6 | // Copyright (c) 2014 Shrikar Archak. All rights reserved.
7 | //
8 |
9 | import UIKit
10 | import XCTest
11 |
12 | class PinterestLayoutTests: XCTestCase {
13 |
14 | override func setUp() {
15 | super.setUp()
16 | // Put setup code here. This method is called before the invocation of each test method in the class.
17 | }
18 |
19 | override func tearDown() {
20 | // Put teardown code here. This method is called after the invocation of each test method in the class.
21 | super.tearDown()
22 | }
23 |
24 | func testExample() {
25 | // This is an example of a functional test case.
26 | XCTAssert(true, "Pass")
27 | }
28 |
29 | func testPerformanceExample() {
30 | // This is an example of a performance test case.
31 | self.measureBlock() {
32 | // Put the code you want to measure the time of here.
33 | }
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/PinterestLayout/DetailViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // DetailViewController.swift
3 | // PinterestLayout
4 | //
5 | // Created by Shrikar Archak on 1/13/15.
6 | // Copyright (c) 2015 Shrikar Archak. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | class DetailViewController: UIViewController {
12 |
13 | @IBOutlet weak var myImageView: UIImageView!
14 | @IBOutlet weak var myLabel: UILabel!
15 | var currImage: UIImage?
16 | var textHeading: String?
17 | override func viewDidLoad() {
18 | super.viewDidLoad()
19 |
20 | println("Detail view controller")
21 | myLabel.text = textHeading
22 | myImageView.image = currImage
23 | }
24 |
25 | override func didReceiveMemoryWarning() {
26 | super.didReceiveMemoryWarning()
27 | // Dispose of any resources that can be recreated.
28 | }
29 |
30 |
31 | /*
32 | // MARK: - Navigation
33 |
34 | // In a storyboard-based application, you will often want to do a little preparation before navigation
35 | override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
36 | // Get the new view controller using segue.destinationViewController.
37 | // Pass the selected object to the new view controller.
38 | }
39 | */
40 |
41 | }
42 |
--------------------------------------------------------------------------------
/PinterestLayout/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | com.shrikar.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 | LSRequiresIPhoneOS
24 |
25 | UILaunchStoryboardName
26 | LaunchScreen
27 | UIMainStoryboardFile
28 | Main
29 | UIRequiredDeviceCapabilities
30 |
31 | armv7
32 |
33 | UISupportedInterfaceOrientations
34 |
35 | UIInterfaceOrientationPortrait
36 | UIInterfaceOrientationLandscapeLeft
37 | UIInterfaceOrientationLandscapeRight
38 |
39 |
40 |
41 |
--------------------------------------------------------------------------------
/PinterestLayout.xcodeproj/project.xcworkspace/xcshareddata/PinterestLayout.xccheckout:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDESourceControlProjectFavoriteDictionaryKey
6 |
7 | IDESourceControlProjectIdentifier
8 | 785A6E97-545A-4E47-BDAF-667E573C84FF
9 | IDESourceControlProjectName
10 | PinterestLayout
11 | IDESourceControlProjectOriginsDictionary
12 |
13 | 2C67A0468AC66F888425555F027D103A36FF2D4F
14 | github.com:sarchak/UICollectionView.git
15 |
16 | IDESourceControlProjectPath
17 | PinterestLayout.xcodeproj
18 | IDESourceControlProjectRelativeInstallPathDictionary
19 |
20 | 2C67A0468AC66F888425555F027D103A36FF2D4F
21 | ../..
22 |
23 | IDESourceControlProjectURL
24 | github.com:sarchak/UICollectionView.git
25 | IDESourceControlProjectVersion
26 | 111
27 | IDESourceControlProjectWCCIdentifier
28 | 2C67A0468AC66F888425555F027D103A36FF2D4F
29 | IDESourceControlProjectWCConfigurations
30 |
31 |
32 | IDESourceControlRepositoryExtensionIdentifierKey
33 | public.vcs.git
34 | IDESourceControlWCCIdentifierKey
35 | 2C67A0468AC66F888425555F027D103A36FF2D4F
36 | IDESourceControlWCCName
37 | PinterestLayout
38 |
39 |
40 |
41 |
42 |
--------------------------------------------------------------------------------
/PinterestLayout/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.swift
3 | // PinterestLayout
4 | //
5 | // Created by Shrikar Archak on 12/21/14.
6 | // Copyright (c) 2014 Shrikar Archak. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @UIApplicationMain
12 | class AppDelegate: UIResponder, UIApplicationDelegate {
13 |
14 | var window: UIWindow?
15 |
16 |
17 | func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
18 | // Override point for customization after application launch.
19 |
20 | let navBar = UINavigationBar.appearance()
21 | // navBar.barTintColor = UIColor.redColor()
22 | // navBar.tintColor = UIColor.redColor()
23 | let font = UIFont(name: "Zapfino", size: 20.0)
24 | navBar.titleTextAttributes = [NSForegroundColorAttributeName : UIColor.redColor(), NSFontAttributeName: font! ]
25 | return true
26 | }
27 |
28 | func applicationWillResignActive(application: UIApplication) {
29 | // 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.
30 | // 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.
31 | }
32 |
33 | func applicationDidEnterBackground(application: UIApplication) {
34 | // 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.
35 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
36 | }
37 |
38 | func applicationWillEnterForeground(application: UIApplication) {
39 | // 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.
40 | }
41 |
42 | func applicationDidBecomeActive(application: UIApplication) {
43 | // 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.
44 | }
45 |
46 | func applicationWillTerminate(application: UIApplication) {
47 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
48 | }
49 |
50 |
51 | }
52 |
53 |
--------------------------------------------------------------------------------
/PinterestLayout/LayoutController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // LayoutController.swift
3 | // PinterestLayout
4 | //
5 | // Created by Shrikar Archak on 12/21/14.
6 | // Copyright (c) 2014 Shrikar Archak. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | let reuseIdentifier = "collCell"
12 |
13 | class LayoutController: UICollectionViewController, UICollectionViewDelegateFlowLayout {
14 | let sectionInsets = UIEdgeInsets(top: 10.0, left: 10.0, bottom: 10.0, right: 10.0)
15 | let titles = ["Sand Harbor, Lake Tahoe - California","Beautiful View of Manhattan skyline.","Watcher in the Fog","Great Smoky Mountains National Park, Tennessee","Most beautiful place"]
16 | override func viewDidLoad() {
17 | super.viewDidLoad()
18 | }
19 |
20 | override func didReceiveMemoryWarning() {
21 | super.didReceiveMemoryWarning()
22 | // Dispose of any resources that can be recreated.
23 | }
24 |
25 | // MARK: UICollectionViewDataSource
26 |
27 | override func numberOfSectionsInCollectionView(collectionView: UICollectionView) -> Int {
28 | //#warning Incomplete method implementation -- Return the number of sections
29 | return 1
30 | }
31 |
32 |
33 | override func collectionView(collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
34 | //#warning Incomplete method implementation -- Return the number of items in the section
35 | return 50
36 | }
37 |
38 |
39 | override func collectionView(collectionView: UICollectionView, cellForItemAtIndexPath indexPath: NSIndexPath) -> UICollectionViewCell {
40 | let cell = collectionView.dequeueReusableCellWithReuseIdentifier(reuseIdentifier, forIndexPath: indexPath) as CollectionViewCell
41 | cell.title.text = self.titles[indexPath.row % 5]
42 | let curr = indexPath.row % 5 + 1
43 | let imgName = "pin\(curr).jpg"
44 | cell.pinImage.image = UIImage(named: imgName)
45 |
46 | return cell
47 | }
48 |
49 |
50 |
51 |
52 | func collectionView(collectionView: UICollectionView!,
53 | layout collectionViewLayout: UICollectionViewLayout!,
54 | sizeForItemAtIndexPath indexPath: NSIndexPath!) -> CGSize {
55 | return CGSize(width: 170, height: 300)
56 | }
57 |
58 |
59 |
60 |
61 | func collectionView(collectionView: UICollectionView!,
62 | layout collectionViewLayout: UICollectionViewLayout!,
63 | insetForSectionAtIndex section: Int) -> UIEdgeInsets {
64 | return sectionInsets
65 | }
66 |
67 | override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
68 | println(segue.identifier)
69 | println(sender)
70 | if(segue.identifier == "detail"){
71 | let cell = sender as CollectionViewCell
72 | let indexPath = collectionView?.indexPathForCell(cell)
73 | let vc = segue.destinationViewController as DetailViewController
74 |
75 | let curr = indexPath!.row % 5 + 1
76 | let imgName = "pin\(curr).jpg"
77 |
78 | println(vc)
79 | vc.currImage = UIImage(named: imgName)
80 | vc.textHeading = self.titles[indexPath!.row % 5]
81 | //
82 | // vc.heading.text = self.titles[0]
83 | // vc.imageView.image = UIImage(named: imgName)
84 | }
85 | }
86 |
87 |
88 |
89 | }
90 |
--------------------------------------------------------------------------------
/PinterestLayout/Base.lproj/LaunchScreen.xib:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
20 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
--------------------------------------------------------------------------------
/PinterestLayout.xcodeproj/xcuserdata/shrikar.xcuserdatad/xcschemes/PinterestLayout.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
29 |
35 |
36 |
37 |
38 |
39 |
44 |
45 |
47 |
53 |
54 |
55 |
56 |
57 |
63 |
64 |
65 |
66 |
75 |
76 |
82 |
83 |
84 |
85 |
86 |
87 |
93 |
94 |
100 |
101 |
102 |
103 |
105 |
106 |
109 |
110 |
111 |
--------------------------------------------------------------------------------
/PinterestLayout/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
--------------------------------------------------------------------------------
/PinterestLayout.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 56144EA31A474E6F00AABFD3 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 56144EA21A474E6F00AABFD3 /* AppDelegate.swift */; };
11 | 56144EA51A474E6F00AABFD3 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 56144EA41A474E6F00AABFD3 /* ViewController.swift */; };
12 | 56144EA81A474E6F00AABFD3 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 56144EA61A474E6F00AABFD3 /* Main.storyboard */; };
13 | 56144EAA1A474E6F00AABFD3 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 56144EA91A474E6F00AABFD3 /* Images.xcassets */; };
14 | 56144EAD1A474E6F00AABFD3 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 56144EAB1A474E6F00AABFD3 /* LaunchScreen.xib */; };
15 | 56144EB91A474E6F00AABFD3 /* PinterestLayoutTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 56144EB81A474E6F00AABFD3 /* PinterestLayoutTests.swift */; };
16 | 56144EC51A47631100AABFD3 /* LayoutController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 56144EC41A47631100AABFD3 /* LayoutController.swift */; };
17 | 56144EC71A47634D00AABFD3 /* CollectionViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 56144EC61A47634D00AABFD3 /* CollectionViewCell.swift */; };
18 | 56144EC91A476E2100AABFD3 /* pin1.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 56144EC81A476E2100AABFD3 /* pin1.jpg */; };
19 | 56144ECE1A4775AA00AABFD3 /* pin2.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 56144ECA1A4775AA00AABFD3 /* pin2.jpg */; };
20 | 56144ED01A4775AA00AABFD3 /* pin4.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 56144ECC1A4775AA00AABFD3 /* pin4.jpg */; };
21 | 56144ED11A4775AA00AABFD3 /* pin5.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 56144ECD1A4775AA00AABFD3 /* pin5.jpg */; };
22 | 56144ED31A47760400AABFD3 /* pin3.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 56144ED21A47760400AABFD3 /* pin3.jpg */; };
23 | 567396251A658E0D000DA32B /* DetailViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 567396241A658E0D000DA32B /* DetailViewController.swift */; };
24 | /* End PBXBuildFile section */
25 |
26 | /* Begin PBXContainerItemProxy section */
27 | 56144EB31A474E6F00AABFD3 /* PBXContainerItemProxy */ = {
28 | isa = PBXContainerItemProxy;
29 | containerPortal = 56144E951A474E6F00AABFD3 /* Project object */;
30 | proxyType = 1;
31 | remoteGlobalIDString = 56144E9C1A474E6F00AABFD3;
32 | remoteInfo = PinterestLayout;
33 | };
34 | /* End PBXContainerItemProxy section */
35 |
36 | /* Begin PBXFileReference section */
37 | 56144E9D1A474E6F00AABFD3 /* PinterestLayout.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = PinterestLayout.app; sourceTree = BUILT_PRODUCTS_DIR; };
38 | 56144EA11A474E6F00AABFD3 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
39 | 56144EA21A474E6F00AABFD3 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
40 | 56144EA41A474E6F00AABFD3 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; };
41 | 56144EA71A474E6F00AABFD3 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
42 | 56144EA91A474E6F00AABFD3 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; };
43 | 56144EAC1A474E6F00AABFD3 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; };
44 | 56144EB21A474E6F00AABFD3 /* PinterestLayoutTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = PinterestLayoutTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
45 | 56144EB71A474E6F00AABFD3 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
46 | 56144EB81A474E6F00AABFD3 /* PinterestLayoutTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PinterestLayoutTests.swift; sourceTree = ""; };
47 | 56144EC41A47631100AABFD3 /* LayoutController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LayoutController.swift; sourceTree = ""; };
48 | 56144EC61A47634D00AABFD3 /* CollectionViewCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CollectionViewCell.swift; sourceTree = ""; };
49 | 56144EC81A476E2100AABFD3 /* pin1.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = pin1.jpg; sourceTree = ""; };
50 | 56144ECA1A4775AA00AABFD3 /* pin2.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = pin2.jpg; sourceTree = ""; };
51 | 56144ECC1A4775AA00AABFD3 /* pin4.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = pin4.jpg; sourceTree = ""; };
52 | 56144ECD1A4775AA00AABFD3 /* pin5.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = pin5.jpg; sourceTree = ""; };
53 | 56144ED21A47760400AABFD3 /* pin3.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = pin3.jpg; sourceTree = ""; };
54 | 567396241A658E0D000DA32B /* DetailViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = DetailViewController.swift; sourceTree = ""; };
55 | /* End PBXFileReference section */
56 |
57 | /* Begin PBXFrameworksBuildPhase section */
58 | 56144E9A1A474E6F00AABFD3 /* Frameworks */ = {
59 | isa = PBXFrameworksBuildPhase;
60 | buildActionMask = 2147483647;
61 | files = (
62 | );
63 | runOnlyForDeploymentPostprocessing = 0;
64 | };
65 | 56144EAF1A474E6F00AABFD3 /* Frameworks */ = {
66 | isa = PBXFrameworksBuildPhase;
67 | buildActionMask = 2147483647;
68 | files = (
69 | );
70 | runOnlyForDeploymentPostprocessing = 0;
71 | };
72 | /* End PBXFrameworksBuildPhase section */
73 |
74 | /* Begin PBXGroup section */
75 | 56144E941A474E6F00AABFD3 = {
76 | isa = PBXGroup;
77 | children = (
78 | 56144E9F1A474E6F00AABFD3 /* PinterestLayout */,
79 | 56144EB51A474E6F00AABFD3 /* PinterestLayoutTests */,
80 | 56144E9E1A474E6F00AABFD3 /* Products */,
81 | );
82 | sourceTree = "";
83 | };
84 | 56144E9E1A474E6F00AABFD3 /* Products */ = {
85 | isa = PBXGroup;
86 | children = (
87 | 56144E9D1A474E6F00AABFD3 /* PinterestLayout.app */,
88 | 56144EB21A474E6F00AABFD3 /* PinterestLayoutTests.xctest */,
89 | );
90 | name = Products;
91 | sourceTree = "";
92 | };
93 | 56144E9F1A474E6F00AABFD3 /* PinterestLayout */ = {
94 | isa = PBXGroup;
95 | children = (
96 | 56144EA21A474E6F00AABFD3 /* AppDelegate.swift */,
97 | 56144EA41A474E6F00AABFD3 /* ViewController.swift */,
98 | 56144EA61A474E6F00AABFD3 /* Main.storyboard */,
99 | 56144EA91A474E6F00AABFD3 /* Images.xcassets */,
100 | 56144EAB1A474E6F00AABFD3 /* LaunchScreen.xib */,
101 | 56144EA01A474E6F00AABFD3 /* Supporting Files */,
102 | 56144EC41A47631100AABFD3 /* LayoutController.swift */,
103 | 56144EC61A47634D00AABFD3 /* CollectionViewCell.swift */,
104 | 567396241A658E0D000DA32B /* DetailViewController.swift */,
105 | );
106 | path = PinterestLayout;
107 | sourceTree = "";
108 | };
109 | 56144EA01A474E6F00AABFD3 /* Supporting Files */ = {
110 | isa = PBXGroup;
111 | children = (
112 | 56144EC81A476E2100AABFD3 /* pin1.jpg */,
113 | 56144ED21A47760400AABFD3 /* pin3.jpg */,
114 | 56144ECA1A4775AA00AABFD3 /* pin2.jpg */,
115 | 56144ECC1A4775AA00AABFD3 /* pin4.jpg */,
116 | 56144ECD1A4775AA00AABFD3 /* pin5.jpg */,
117 | 56144EA11A474E6F00AABFD3 /* Info.plist */,
118 | );
119 | name = "Supporting Files";
120 | sourceTree = "";
121 | };
122 | 56144EB51A474E6F00AABFD3 /* PinterestLayoutTests */ = {
123 | isa = PBXGroup;
124 | children = (
125 | 56144EB81A474E6F00AABFD3 /* PinterestLayoutTests.swift */,
126 | 56144EB61A474E6F00AABFD3 /* Supporting Files */,
127 | );
128 | path = PinterestLayoutTests;
129 | sourceTree = "";
130 | };
131 | 56144EB61A474E6F00AABFD3 /* Supporting Files */ = {
132 | isa = PBXGroup;
133 | children = (
134 | 56144EB71A474E6F00AABFD3 /* Info.plist */,
135 | );
136 | name = "Supporting Files";
137 | sourceTree = "";
138 | };
139 | /* End PBXGroup section */
140 |
141 | /* Begin PBXNativeTarget section */
142 | 56144E9C1A474E6F00AABFD3 /* PinterestLayout */ = {
143 | isa = PBXNativeTarget;
144 | buildConfigurationList = 56144EBC1A474E6F00AABFD3 /* Build configuration list for PBXNativeTarget "PinterestLayout" */;
145 | buildPhases = (
146 | 56144E991A474E6F00AABFD3 /* Sources */,
147 | 56144E9A1A474E6F00AABFD3 /* Frameworks */,
148 | 56144E9B1A474E6F00AABFD3 /* Resources */,
149 | );
150 | buildRules = (
151 | );
152 | dependencies = (
153 | );
154 | name = PinterestLayout;
155 | productName = PinterestLayout;
156 | productReference = 56144E9D1A474E6F00AABFD3 /* PinterestLayout.app */;
157 | productType = "com.apple.product-type.application";
158 | };
159 | 56144EB11A474E6F00AABFD3 /* PinterestLayoutTests */ = {
160 | isa = PBXNativeTarget;
161 | buildConfigurationList = 56144EBF1A474E6F00AABFD3 /* Build configuration list for PBXNativeTarget "PinterestLayoutTests" */;
162 | buildPhases = (
163 | 56144EAE1A474E6F00AABFD3 /* Sources */,
164 | 56144EAF1A474E6F00AABFD3 /* Frameworks */,
165 | 56144EB01A474E6F00AABFD3 /* Resources */,
166 | );
167 | buildRules = (
168 | );
169 | dependencies = (
170 | 56144EB41A474E6F00AABFD3 /* PBXTargetDependency */,
171 | );
172 | name = PinterestLayoutTests;
173 | productName = PinterestLayoutTests;
174 | productReference = 56144EB21A474E6F00AABFD3 /* PinterestLayoutTests.xctest */;
175 | productType = "com.apple.product-type.bundle.unit-test";
176 | };
177 | /* End PBXNativeTarget section */
178 |
179 | /* Begin PBXProject section */
180 | 56144E951A474E6F00AABFD3 /* Project object */ = {
181 | isa = PBXProject;
182 | attributes = {
183 | LastUpgradeCheck = 0610;
184 | ORGANIZATIONNAME = "Shrikar Archak";
185 | TargetAttributes = {
186 | 56144E9C1A474E6F00AABFD3 = {
187 | CreatedOnToolsVersion = 6.1.1;
188 | };
189 | 56144EB11A474E6F00AABFD3 = {
190 | CreatedOnToolsVersion = 6.1.1;
191 | TestTargetID = 56144E9C1A474E6F00AABFD3;
192 | };
193 | };
194 | };
195 | buildConfigurationList = 56144E981A474E6F00AABFD3 /* Build configuration list for PBXProject "PinterestLayout" */;
196 | compatibilityVersion = "Xcode 3.2";
197 | developmentRegion = English;
198 | hasScannedForEncodings = 0;
199 | knownRegions = (
200 | en,
201 | Base,
202 | );
203 | mainGroup = 56144E941A474E6F00AABFD3;
204 | productRefGroup = 56144E9E1A474E6F00AABFD3 /* Products */;
205 | projectDirPath = "";
206 | projectRoot = "";
207 | targets = (
208 | 56144E9C1A474E6F00AABFD3 /* PinterestLayout */,
209 | 56144EB11A474E6F00AABFD3 /* PinterestLayoutTests */,
210 | );
211 | };
212 | /* End PBXProject section */
213 |
214 | /* Begin PBXResourcesBuildPhase section */
215 | 56144E9B1A474E6F00AABFD3 /* Resources */ = {
216 | isa = PBXResourcesBuildPhase;
217 | buildActionMask = 2147483647;
218 | files = (
219 | 56144EA81A474E6F00AABFD3 /* Main.storyboard in Resources */,
220 | 56144ED31A47760400AABFD3 /* pin3.jpg in Resources */,
221 | 56144ECE1A4775AA00AABFD3 /* pin2.jpg in Resources */,
222 | 56144ED11A4775AA00AABFD3 /* pin5.jpg in Resources */,
223 | 56144EAD1A474E6F00AABFD3 /* LaunchScreen.xib in Resources */,
224 | 56144EAA1A474E6F00AABFD3 /* Images.xcassets in Resources */,
225 | 56144EC91A476E2100AABFD3 /* pin1.jpg in Resources */,
226 | 56144ED01A4775AA00AABFD3 /* pin4.jpg in Resources */,
227 | );
228 | runOnlyForDeploymentPostprocessing = 0;
229 | };
230 | 56144EB01A474E6F00AABFD3 /* Resources */ = {
231 | isa = PBXResourcesBuildPhase;
232 | buildActionMask = 2147483647;
233 | files = (
234 | );
235 | runOnlyForDeploymentPostprocessing = 0;
236 | };
237 | /* End PBXResourcesBuildPhase section */
238 |
239 | /* Begin PBXSourcesBuildPhase section */
240 | 56144E991A474E6F00AABFD3 /* Sources */ = {
241 | isa = PBXSourcesBuildPhase;
242 | buildActionMask = 2147483647;
243 | files = (
244 | 56144EA51A474E6F00AABFD3 /* ViewController.swift in Sources */,
245 | 56144EA31A474E6F00AABFD3 /* AppDelegate.swift in Sources */,
246 | 567396251A658E0D000DA32B /* DetailViewController.swift in Sources */,
247 | 56144EC71A47634D00AABFD3 /* CollectionViewCell.swift in Sources */,
248 | 56144EC51A47631100AABFD3 /* LayoutController.swift in Sources */,
249 | );
250 | runOnlyForDeploymentPostprocessing = 0;
251 | };
252 | 56144EAE1A474E6F00AABFD3 /* Sources */ = {
253 | isa = PBXSourcesBuildPhase;
254 | buildActionMask = 2147483647;
255 | files = (
256 | 56144EB91A474E6F00AABFD3 /* PinterestLayoutTests.swift in Sources */,
257 | );
258 | runOnlyForDeploymentPostprocessing = 0;
259 | };
260 | /* End PBXSourcesBuildPhase section */
261 |
262 | /* Begin PBXTargetDependency section */
263 | 56144EB41A474E6F00AABFD3 /* PBXTargetDependency */ = {
264 | isa = PBXTargetDependency;
265 | target = 56144E9C1A474E6F00AABFD3 /* PinterestLayout */;
266 | targetProxy = 56144EB31A474E6F00AABFD3 /* PBXContainerItemProxy */;
267 | };
268 | /* End PBXTargetDependency section */
269 |
270 | /* Begin PBXVariantGroup section */
271 | 56144EA61A474E6F00AABFD3 /* Main.storyboard */ = {
272 | isa = PBXVariantGroup;
273 | children = (
274 | 56144EA71A474E6F00AABFD3 /* Base */,
275 | );
276 | name = Main.storyboard;
277 | sourceTree = "";
278 | };
279 | 56144EAB1A474E6F00AABFD3 /* LaunchScreen.xib */ = {
280 | isa = PBXVariantGroup;
281 | children = (
282 | 56144EAC1A474E6F00AABFD3 /* Base */,
283 | );
284 | name = LaunchScreen.xib;
285 | sourceTree = "";
286 | };
287 | /* End PBXVariantGroup section */
288 |
289 | /* Begin XCBuildConfiguration section */
290 | 56144EBA1A474E6F00AABFD3 /* Debug */ = {
291 | isa = XCBuildConfiguration;
292 | buildSettings = {
293 | ALWAYS_SEARCH_USER_PATHS = NO;
294 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
295 | CLANG_CXX_LIBRARY = "libc++";
296 | CLANG_ENABLE_MODULES = YES;
297 | CLANG_ENABLE_OBJC_ARC = YES;
298 | CLANG_WARN_BOOL_CONVERSION = YES;
299 | CLANG_WARN_CONSTANT_CONVERSION = YES;
300 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
301 | CLANG_WARN_EMPTY_BODY = YES;
302 | CLANG_WARN_ENUM_CONVERSION = YES;
303 | CLANG_WARN_INT_CONVERSION = YES;
304 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
305 | CLANG_WARN_UNREACHABLE_CODE = YES;
306 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
307 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
308 | COPY_PHASE_STRIP = NO;
309 | ENABLE_STRICT_OBJC_MSGSEND = YES;
310 | GCC_C_LANGUAGE_STANDARD = gnu99;
311 | GCC_DYNAMIC_NO_PIC = NO;
312 | GCC_OPTIMIZATION_LEVEL = 0;
313 | GCC_PREPROCESSOR_DEFINITIONS = (
314 | "DEBUG=1",
315 | "$(inherited)",
316 | );
317 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
318 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
319 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
320 | GCC_WARN_UNDECLARED_SELECTOR = YES;
321 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
322 | GCC_WARN_UNUSED_FUNCTION = YES;
323 | GCC_WARN_UNUSED_VARIABLE = YES;
324 | IPHONEOS_DEPLOYMENT_TARGET = 8.1;
325 | MTL_ENABLE_DEBUG_INFO = YES;
326 | ONLY_ACTIVE_ARCH = YES;
327 | SDKROOT = iphoneos;
328 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
329 | };
330 | name = Debug;
331 | };
332 | 56144EBB1A474E6F00AABFD3 /* Release */ = {
333 | isa = XCBuildConfiguration;
334 | buildSettings = {
335 | ALWAYS_SEARCH_USER_PATHS = NO;
336 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
337 | CLANG_CXX_LIBRARY = "libc++";
338 | CLANG_ENABLE_MODULES = YES;
339 | CLANG_ENABLE_OBJC_ARC = YES;
340 | CLANG_WARN_BOOL_CONVERSION = YES;
341 | CLANG_WARN_CONSTANT_CONVERSION = YES;
342 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
343 | CLANG_WARN_EMPTY_BODY = YES;
344 | CLANG_WARN_ENUM_CONVERSION = YES;
345 | CLANG_WARN_INT_CONVERSION = YES;
346 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
347 | CLANG_WARN_UNREACHABLE_CODE = YES;
348 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
349 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
350 | COPY_PHASE_STRIP = YES;
351 | ENABLE_NS_ASSERTIONS = NO;
352 | ENABLE_STRICT_OBJC_MSGSEND = YES;
353 | GCC_C_LANGUAGE_STANDARD = gnu99;
354 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
355 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
356 | GCC_WARN_UNDECLARED_SELECTOR = YES;
357 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
358 | GCC_WARN_UNUSED_FUNCTION = YES;
359 | GCC_WARN_UNUSED_VARIABLE = YES;
360 | IPHONEOS_DEPLOYMENT_TARGET = 8.1;
361 | MTL_ENABLE_DEBUG_INFO = NO;
362 | SDKROOT = iphoneos;
363 | VALIDATE_PRODUCT = YES;
364 | };
365 | name = Release;
366 | };
367 | 56144EBD1A474E6F00AABFD3 /* Debug */ = {
368 | isa = XCBuildConfiguration;
369 | buildSettings = {
370 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
371 | INFOPLIST_FILE = PinterestLayout/Info.plist;
372 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
373 | PRODUCT_NAME = "$(TARGET_NAME)";
374 | TARGETED_DEVICE_FAMILY = "1,2";
375 | };
376 | name = Debug;
377 | };
378 | 56144EBE1A474E6F00AABFD3 /* Release */ = {
379 | isa = XCBuildConfiguration;
380 | buildSettings = {
381 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
382 | INFOPLIST_FILE = PinterestLayout/Info.plist;
383 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
384 | PRODUCT_NAME = "$(TARGET_NAME)";
385 | TARGETED_DEVICE_FAMILY = "1,2";
386 | };
387 | name = Release;
388 | };
389 | 56144EC01A474E6F00AABFD3 /* Debug */ = {
390 | isa = XCBuildConfiguration;
391 | buildSettings = {
392 | BUNDLE_LOADER = "$(TEST_HOST)";
393 | FRAMEWORK_SEARCH_PATHS = (
394 | "$(SDKROOT)/Developer/Library/Frameworks",
395 | "$(inherited)",
396 | );
397 | GCC_PREPROCESSOR_DEFINITIONS = (
398 | "DEBUG=1",
399 | "$(inherited)",
400 | );
401 | INFOPLIST_FILE = PinterestLayoutTests/Info.plist;
402 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
403 | PRODUCT_NAME = "$(TARGET_NAME)";
404 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/PinterestLayout.app/PinterestLayout";
405 | };
406 | name = Debug;
407 | };
408 | 56144EC11A474E6F00AABFD3 /* Release */ = {
409 | isa = XCBuildConfiguration;
410 | buildSettings = {
411 | BUNDLE_LOADER = "$(TEST_HOST)";
412 | FRAMEWORK_SEARCH_PATHS = (
413 | "$(SDKROOT)/Developer/Library/Frameworks",
414 | "$(inherited)",
415 | );
416 | INFOPLIST_FILE = PinterestLayoutTests/Info.plist;
417 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
418 | PRODUCT_NAME = "$(TARGET_NAME)";
419 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/PinterestLayout.app/PinterestLayout";
420 | };
421 | name = Release;
422 | };
423 | /* End XCBuildConfiguration section */
424 |
425 | /* Begin XCConfigurationList section */
426 | 56144E981A474E6F00AABFD3 /* Build configuration list for PBXProject "PinterestLayout" */ = {
427 | isa = XCConfigurationList;
428 | buildConfigurations = (
429 | 56144EBA1A474E6F00AABFD3 /* Debug */,
430 | 56144EBB1A474E6F00AABFD3 /* Release */,
431 | );
432 | defaultConfigurationIsVisible = 0;
433 | defaultConfigurationName = Release;
434 | };
435 | 56144EBC1A474E6F00AABFD3 /* Build configuration list for PBXNativeTarget "PinterestLayout" */ = {
436 | isa = XCConfigurationList;
437 | buildConfigurations = (
438 | 56144EBD1A474E6F00AABFD3 /* Debug */,
439 | 56144EBE1A474E6F00AABFD3 /* Release */,
440 | );
441 | defaultConfigurationIsVisible = 0;
442 | defaultConfigurationName = Release;
443 | };
444 | 56144EBF1A474E6F00AABFD3 /* Build configuration list for PBXNativeTarget "PinterestLayoutTests" */ = {
445 | isa = XCConfigurationList;
446 | buildConfigurations = (
447 | 56144EC01A474E6F00AABFD3 /* Debug */,
448 | 56144EC11A474E6F00AABFD3 /* Release */,
449 | );
450 | defaultConfigurationIsVisible = 0;
451 | defaultConfigurationName = Release;
452 | };
453 | /* End XCConfigurationList section */
454 | };
455 | rootObject = 56144E951A474E6F00AABFD3 /* Project object */;
456 | }
457 |
--------------------------------------------------------------------------------