This file contains hidden or 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
| #!/bin/sh | |
| echo "This script will take an input folder full of images and assuming they're all retina sized, output the second folder to have retina and standard sized images." | |
| if [ ! $# == 2 ]; then | |
| echo "Usage: $0 in out" | |
| exit | |
| fi | |
| if [ ! -d $1 ] |
This file contains hidden or 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 | |
| # Made by Pieter de Bie <[email protected]> | |
| # Based on a "Pastie" task by someone | |
| require "tempfile" | |
| GIST_URL = 'http://gist.github.com/gists' | |
| GIST_LOGIN_URL = 'https://gist.github.com/session' | |
| USERNAME = "martinisoft" | |
| TOKEN = "6ef8395fecf207165f1a82178ae1b984" |
This file contains hidden or 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
| (function(){ | |
| var event_names = { | |
| "click" : "" , | |
| "tweet" : "", | |
| "retweet" : "source_tweet_id", | |
| "follow" : "screen_name", | |
| "favorite" : "tweet_id" | |
| }; | |
| for(var event_name in event_names) |
This file contains hidden or 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
| desc "Generate Documentation" | |
| task :doc do | |
| root = File.dirname __FILE__ | |
| perl = %x[which perl].chomp | |
| jsdoc_options = [ | |
| "--recursive", | |
| "--directory #{root}/doc", | |
| "--project-name AwesomeProject" | |
| ].join(" ") |
This file contains hidden or 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
| NSEnumerator *enumerator = [itemViewContainer.subviews objectEnumerator]; | |
| UIView *subview; | |
| while (subview = [enumerator nextObject]) { | |
| [subview removeFromSuperview]; | |
| } |
This file contains hidden or 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
| #import <UIKit/UIKit.h> | |
| #define kSCNavigationBarBackgroundImageTag 6183746 | |
| #define kSCNavigationBarTintColor [UIColor colorWithRed:0.54 green:0.18 blue:0.03 alpha:1.0] | |
| @interface SCAppUtils : NSObject | |
| { | |
| } | |
| + (void)customizeNavigationController:(UINavigationController *)navController; |
This file contains hidden or 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
| // LocationServices.h | |
| #import <Foundation/Foundation.h> | |
| #import <CoreLocation/CoreLocation.h> | |
| @interface LocationServices : NSObject <CLLocationManagerDelegate> { | |
| CLLocationManager *locationManager; | |
| CLLocation *currentLocation; | |
This file contains hidden or 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
| //CORE DATA | |
| //FETCHING PROCESS SNIPPET | |
| NSManagedObjectContext *sharedContext = [(AppDelegate_Shared *)[[UIApplication sharedApplication] delegate] managedObjectContext]; | |
| NSFetchRequest *request = [[NSFetchRequest alloc] init]; | |
| NSEntityDescription *entity = [NSEntityDescription entityForName:@"Currency" inManagedObjectContext:sharedContext]; | |
| [request setEntity:entity]; | |
| currencies = [[NSArray alloc ] initWithArray:[sharedContext executeFetchRequest:request error:nil]]; |
This file contains hidden or 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)scrollViewWillBeginDragging:(UIScrollView *)scrollView | |
| { | |
| if(_reachedEndOfFeed) return; | |
| if(!_dynamicFeed) return; | |
| DLog(); | |
| if (!reloading) | |
| { | |
| checkForRefresh = YES; // only check offset when dragging | |
| } |
This file contains hidden or 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
| // A small variant of Jeff Lamarche code as seen here : http://iphonedevelopment.blogspot.com/2010/05/custom-alert-views.html | |
| // | |
| // CustomAlertView.m | |
| // Custom Alert View | |
| // | |
| // Created by jeff on 5/17/10. | |
| // Copyright 2010 __MyCompanyName__. All rights reserved. | |
| // |