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
NSIndexPath *indexPath = [self.tableView indexPathForRowAtPoint:location]; |
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
[previewingContext setSourceRect:[self.tableView rectForRowAtIndexPath:indexPath]]; |
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
- (void)previewingContext:(id<UIViewControllerPreviewing>)previewingContext | |
commitViewController:(UIViewController *)viewControllerToCommit | |
{ | |
// get the peek controller (on screen currently) | |
HNTMemberPeekViewController *peekController = (HNTMemberPeekViewController *)viewControllerToCommit; | |
// get its data object | |
HNMemberLite *memberLite = peekController.memberLite; | |
// handle it as you'd handle normal cell tap action | |
[self memberAction:memberLite]; |
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
- (UIViewController *)previewingContext:(id<UIViewControllerPreviewing>)previewingContext | |
viewControllerForLocation:(CGPoint)location | |
{ | |
// query the collectionView for index corresponting to the touch location | |
NSIndexPath *indexPath = [self.collectionView indexPathForItemAtPoint:location]; | |
// just in case | |
if (!indexPath) { return nil; } | |
// get the data object corresponding to the pressed cell |
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
if (iOS_9) { | |
[self registerForPreviewingWithDelegate:self | |
sourceView:self.collectionView]; | |
} |
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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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
Code Sign warning: Specified PROVISIONING_PROFILE (98E447F7-E39B-4F0D-842B-6B588BC2D619) not found and no CODE_SIGN_IDENTITY specified. Ignoring PROVISIONING_PROFILE for now. This will become an error in the future. |
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
xcodebuild | |
=========================================== | |
xcodebuild | |
xcodebuild -workspace Pexeso.xcworkspace | |
xcodebuild -workspace Pexeso.xcworkspace -scheme Pexeso | |
xcodebuild -workspace Pexeso.xcworkspace -scheme Pexeso -configuration Release |
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
#!/usr/bin/env ruby | |
if not ARGV[0] | |
puts "usage: ./script <icon.png>" | |
return | |
end | |
$icon = ARGV[0] | |
iPhone_dimensions = [ 29, 40, 57, 60 ] |