Skip to content

Commit eeeb015

Browse files
committed
Merge branch 'feature/storyboard' into develop
2 parents a194373 + 3fca2fe commit eeeb015

10 files changed

Lines changed: 428 additions & 49 deletions

Example/Example.xcodeproj/project.pbxproj

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,15 @@
1111
B52819581C90215C007D01D5 /* CustomizedTokenField.swift in Sources */ = {isa = PBXBuildFile; fileRef = B52819571C90215C007D01D5 /* CustomizedTokenField.swift */; };
1212
B548C5A71C8D55A8009D5AEE /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = B548C5A51C8D55A8009D5AEE /* InfoPlist.strings */; };
1313
B548C5A91C8D6150009D5AEE /* ExampleCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = B548C5A81C8D6150009D5AEE /* ExampleCell.swift */; };
14-
B548C5C51C8E91B0009D5AEE /* ICInputAccessoryUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = B548C5C41C8E91B0009D5AEE /* ICInputAccessoryUITests.swift */; };
14+
B548C5C51C8E91B0009D5AEE /* ICTokenFieldUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = B548C5C41C8E91B0009D5AEE /* ICTokenFieldUITests.swift */; };
1515
B5C53E191C92851400AF3489 /* CustomizedTokenViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = B5C53E181C92851400AF3489 /* CustomizedTokenViewController.swift */; };
16+
B5D04CFE1C99A7C900174823 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = B5D04CFD1C99A7C900174823 /* Main.storyboard */; };
17+
B5D04D001C99AF0700174823 /* StoryboardViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = B5D04CFF1C99AF0700174823 /* StoryboardViewController.swift */; };
1618
B5E9F8FF1C8D3B6E00443DC7 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = B5E9F8FE1C8D3B6E00443DC7 /* AppDelegate.swift */; };
1719
B5E9F9011C8D3B6E00443DC7 /* ExampleViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = B5E9F9001C8D3B6E00443DC7 /* ExampleViewController.swift */; };
1820
B5E9F9061C8D3B6E00443DC7 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = B5E9F9051C8D3B6E00443DC7 /* Assets.xcassets */; };
1921
B5E9F9091C8D3B6E00443DC7 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = B5E9F9071C8D3B6E00443DC7 /* LaunchScreen.storyboard */; };
22+
B5F62A5D1C9ECBCB003A1231 /* ICKeyboardDismissTextFieldUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = B5F62A5C1C9ECBCB003A1231 /* ICKeyboardDismissTextFieldUITests.swift */; };
2023
/* End PBXBuildFile section */
2124

2225
/* Begin PBXContainerItemProxy section */
@@ -34,15 +37,18 @@
3437
B548C5A61C8D55A8009D5AEE /* Base */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = Base; path = Base.lproj/InfoPlist.strings; sourceTree = "<group>"; };
3538
B548C5A81C8D6150009D5AEE /* ExampleCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ExampleCell.swift; sourceTree = "<group>"; };
3639
B548C5C21C8E91B0009D5AEE /* ICInputAccessoryUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ICInputAccessoryUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
37-
B548C5C41C8E91B0009D5AEE /* ICInputAccessoryUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ICInputAccessoryUITests.swift; sourceTree = "<group>"; };
40+
B548C5C41C8E91B0009D5AEE /* ICTokenFieldUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ICTokenFieldUITests.swift; sourceTree = "<group>"; };
3841
B548C5C61C8E91B0009D5AEE /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
3942
B5C53E181C92851400AF3489 /* CustomizedTokenViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CustomizedTokenViewController.swift; sourceTree = "<group>"; };
43+
B5D04CFD1C99A7C900174823 /* Main.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Main.storyboard; sourceTree = "<group>"; };
44+
B5D04CFF1C99AF0700174823 /* StoryboardViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = StoryboardViewController.swift; sourceTree = "<group>"; };
4045
B5E9F8FB1C8D3B6E00443DC7 /* Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Example.app; sourceTree = BUILT_PRODUCTS_DIR; };
4146
B5E9F8FE1C8D3B6E00443DC7 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
4247
B5E9F9001C8D3B6E00443DC7 /* ExampleViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ExampleViewController.swift; sourceTree = "<group>"; };
4348
B5E9F9051C8D3B6E00443DC7 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
4449
B5E9F9081C8D3B6E00443DC7 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
4550
B5E9F90A1C8D3B6E00443DC7 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
51+
B5F62A5C1C9ECBCB003A1231 /* ICKeyboardDismissTextFieldUITests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ICKeyboardDismissTextFieldUITests.swift; sourceTree = "<group>"; };
4652
CA708B7D49E7D80A75ED81E3 /* Pods-Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example.debug.xcconfig"; path = "../Pods/Target Support Files/Pods-Example/Pods-Example.debug.xcconfig"; sourceTree = "<group>"; };
4753
D0DB1D3E89AB75183DB104E0 /* Pods_Example.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Example.framework; sourceTree = BUILT_PRODUCTS_DIR; };
4854
FE1A89C8A77ED0438A206A24 /* Pods-Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example.release.xcconfig"; path = "../Pods/Target Support Files/Pods-Example/Pods-Example.release.xcconfig"; sourceTree = "<group>"; };
@@ -87,7 +93,8 @@
8793
B548C5C31C8E91B0009D5AEE /* ICInputAccessoryUITests */ = {
8894
isa = PBXGroup;
8995
children = (
90-
B548C5C41C8E91B0009D5AEE /* ICInputAccessoryUITests.swift */,
96+
B5F62A5C1C9ECBCB003A1231 /* ICKeyboardDismissTextFieldUITests.swift */,
97+
B548C5C41C8E91B0009D5AEE /* ICTokenFieldUITests.swift */,
9198
B548C5C61C8E91B0009D5AEE /* Info.plist */,
9299
);
93100
path = ICInputAccessoryUITests;
@@ -125,6 +132,8 @@
125132
B5E9F90A1C8D3B6E00443DC7 /* Info.plist */,
126133
B548C5A51C8D55A8009D5AEE /* InfoPlist.strings */,
127134
B5E9F9071C8D3B6E00443DC7 /* LaunchScreen.storyboard */,
135+
B5D04CFD1C99A7C900174823 /* Main.storyboard */,
136+
B5D04CFF1C99AF0700174823 /* StoryboardViewController.swift */,
128137
);
129138
path = Example;
130139
sourceTree = "<group>";
@@ -224,6 +233,7 @@
224233
B5E9F9061C8D3B6E00443DC7 /* Assets.xcassets in Resources */,
225234
B548C5A71C8D55A8009D5AEE /* InfoPlist.strings in Resources */,
226235
B5E9F9091C8D3B6E00443DC7 /* LaunchScreen.storyboard in Resources */,
236+
B5D04CFE1C99A7C900174823 /* Main.storyboard in Resources */,
227237
);
228238
runOnlyForDeploymentPostprocessing = 0;
229239
};
@@ -296,7 +306,8 @@
296306
isa = PBXSourcesBuildPhase;
297307
buildActionMask = 2147483647;
298308
files = (
299-
B548C5C51C8E91B0009D5AEE /* ICInputAccessoryUITests.swift in Sources */,
309+
B5F62A5D1C9ECBCB003A1231 /* ICKeyboardDismissTextFieldUITests.swift in Sources */,
310+
B548C5C51C8E91B0009D5AEE /* ICTokenFieldUITests.swift in Sources */,
300311
);
301312
runOnlyForDeploymentPostprocessing = 0;
302313
};
@@ -309,6 +320,7 @@
309320
B5C53E191C92851400AF3489 /* CustomizedTokenViewController.swift in Sources */,
310321
B548C5A91C8D6150009D5AEE /* ExampleCell.swift in Sources */,
311322
B5E9F9011C8D3B6E00443DC7 /* ExampleViewController.swift in Sources */,
323+
B5D04D001C99AF0700174823 /* StoryboardViewController.swift in Sources */,
312324
);
313325
runOnlyForDeploymentPostprocessing = 0;
314326
};

Example/Example/ExampleViewController.swift

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,14 @@ class ExampleViewController: UITableViewController {
3535
CustomizedTokenField.self
3636
]
3737

38+
private lazy var flipButton: UIButton = {
39+
let _button = UIButton(type: .System)
40+
_button.frame = CGRect(x: 0, y: 0, width: UIScreen.mainScreen().bounds.width, height: 88)
41+
_button.setTitle("Storyboard", forState: .Normal)
42+
_button.addTarget(self, action: Selector("showStoryboard:"), forControlEvents: .TouchUpInside)
43+
return _button
44+
}()
45+
3846
// MARK: - Initialization
3947

4048
convenience init() {
@@ -47,6 +55,8 @@ class ExampleViewController: UITableViewController {
4755
override func loadView() {
4856
super.loadView()
4957
tableView.registerClass(ExampleCell.self, forCellReuseIdentifier: NSStringFromClass(ExampleCell.self))
58+
tableView.tableFooterView = flipButton
59+
tableView.tableFooterView?.userInteractionEnabled
5060
}
5161

5262
// MARK: - UITableViewDataSource
@@ -113,4 +123,13 @@ class ExampleViewController: UITableViewController {
113123
}
114124
}
115125

126+
// MARK: - UIResponder Callbacks
127+
128+
@IBAction private func showStoryboard(sender: UIButton) {
129+
if let controller = UIStoryboard(name: "Main", bundle: NSBundle.mainBundle()).instantiateInitialViewController() {
130+
controller.modalTransitionStyle = .FlipHorizontal
131+
presentViewController(controller, animated: true, completion: nil)
132+
}
133+
}
134+
116135
}

0 commit comments

Comments
 (0)