Skip to content

Instantly share code, notes, and snippets.

View veritech's full-sized avatar

Jonathan Dalrymple veritech

View GitHub Profile
//This Youtube url
http://www.youtube.com/watch?v=0p8NfH-vZGU&feature=featured
//creates this HTML 5 video tag src
http://v2.lscache3.c.youtube.com/videoplayback?
ip=0.0.0.0&
sparams=id%2Cexpire%2Cip%2Cipbits%2Citag%2Calgorithm%2Cburst%2Cfactor%2Coc%3AU0dVTVRMVF9FSkNNNV9MRlhJ&
fexp=901802&
algorithm=throttle-factor&
itag=18&
//
// CLLocation-Extras.m
//
// Created by Jonathan Dalrymple on 21/03/2010.
// Copyright 2010 Float:Right. All rights reserved.
//
#import "CLLocation-Extras.h"
// Created by Jonathan Dalrymple on 28/03/2010.
// Copyright 2010 Float:Right. All rights reserved.
//
#import "CLLocationManager-Mock.h"
@implementation CLLocationManager (Mock)
//
// FROAuthRequest.m
//
// Created by Jonathan Dalrymple on 12/04/2010.
// Copyright 2010 Float:Right. All rights reserved.
//
#import "FROAuthRequest.h"
@interface FROAuthRequest(private)
//
// FROAuthRequest.m
// kroonjuwelen
//
// Created by Jonathan Dalrymple on 12/04/2010.
// Copyright 2010 Float:Right. All rights reserved.
//
#import "FROAuthRequest.h"
#import <Foundation/Foundation.h>
#define kApplicationFontSize 14.0f
#define kApplicationBoldFontName @"HelveticaNeue-Bold"
#define kApplicationFontName @"HelveticaNeue"
@interface UIFont(custom)
+(UIFont*) applicationFont;
//MGTwitterEngine
- (NSString *)_encodeString:(NSString *)string
{
NSString *result = (NSString *)CFURLCreateStringByAddingPercentEscapes(NULL,
(CFStringRef)string,
NULL,
(CFStringRef)@";/?:@&=$+{}<>,",
kCFStringEncodingUTF8);
return [result autorelease];
}
@veritech
veritech / gist:704938
Created November 18, 2010 13:00
DebugLog
#ifdef 1
#define DebugLog( s, ... ) NSLog( @"<%p %@:(%d)> %@", self, [[NSString stringWithUTF8String:__FILE__] lastPathComponent], __LINE__, [NSString stringWithFormat:(s), ##__VA_ARGS__] )
#else
#define DebugLog( s, ... )
#endif
@veritech
veritech / FRImageOperation.m
Created December 16, 2010 09:10
Processing Images on a background thread, and wrapping them up in NSOperations ... just to be pretty
#import <Foundation/Foundation.h>
#import <QuartzCore/QuartzCore.h>
@interface FRImageOperation : NSOperation {
}
@end
@veritech
veritech / NSNotificationQueue.m
Created January 4, 2011 21:51
NSNotificationQueue
-(void) setNeedsReload{
//[self reload];
NSNotification *notification;
notification = [NSNotification notificationWithName:@"reloadNotification"
object:self];
[[NSNotificationQueue defaultQueue] enqueueNotification:notification
postingStyle:NSPostNow