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
#!/bin/sh | |
#Modified from http://furbo.org/2009/03/03/open-sesame/ | |
if [ -z "$1" ]; then | |
echo "usage: $0 <app> [ Preferences | <document> ]" | |
else | |
app=`ls -1td ~/Library/Application\ Support/iPhone\ Simulator/*/Applications/*/$1.app | head -1` | |
#app=`ls -1td ~/Library/Application\ Support/iPhone\ Simulator/User/Applications/*/$1.app | head -1` | |
dir=`dirname "$app"` |
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
// This goes into the header file. | |
void moCampfireSpeak(NSString* aString, NSString* aRoomIDString, NSString* aSubdomainString, NSString* aTokenString); | |
// This goes into the implementation file. | |
// You need the room ID, not room name. You can get it from the campfire room URL. | |
void moCampfireSpeak(NSString* aString, NSString* aRoomIDString, NSString* aSubdomainString, NSString* aTokenString) { | |
NSString* url = [NSString stringWithFormat:@"https://%@.campfirenow.com/room/%@/speak.json", aSubdomainString, aRoomIDString]; | |
NSString* postString = [NSString stringWithFormat:@"<message><type>%@</type><body>%@</body></message>", @"TextMessage", aString]; | |
NSMutableURLRequest* request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:url] cachePolicy:NSURLRequestReloadIgnoringCacheData timeoutInterval:60.0]; |
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
//Courtesy of https://github.com/InderKumarRathore/DeviceUtil/blob/master/DeviceUtil.m | |
- (NSString*)moHardwareDescription { | |
NSString *hardware = [self moHardwareString]; | |
if ([hardware isEqualToString:@"iPhone1,1"]) return @"iPhone 2G"; | |
if ([hardware isEqualToString:@"iPhone1,2"]) return @"iPhone 3G"; | |
if ([hardware isEqualToString:@"iPhone2,1"]) return @"iPhone 3GS"; | |
if ([hardware isEqualToString:@"iPhone3,1"]) return @"iPhone 4"; | |
if ([hardware isEqualToString:@"iPhone3,2"]) return @"iPhone 4"; | |
if ([hardware isEqualToString:@"iPhone3,3"]) return @"iPhone 4 (CDMA)"; | |
if ([hardware isEqualToString:@"iPhone4,1"]) return @"iPhone 4S"; |
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
// | |
// AVAsset+VideoOrientation.h | |
// | |
// Created by Luca Bernardi on 19/09/12. | |
// Copyright (c) 2012 Luca Bernardi. All rights reserved. | |
// | |
#import <AVFoundation/AVFoundation.h> | |
typedef enum { | |
LBVideoOrientationUp, //Device starts recording in Portrait |
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
env = if ENV['dev'] == '1' | |
'dev' | |
elsif ENV['adhoc'] == '1' | |
'adhoc' | |
else | |
'dev' #default | |
end | |
if env == 'dev' | |
app.codesign_certificate = 'iPhone Developer: Hwee Boon Yar (something)' |
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
it "verify #use_weak_callbacks" do | |
class ButtonParentView1 < UIView | |
def dealloc | |
p "dealloc #{self} tag: #{tag}" | |
super | |
end | |
def create_btn | |
sub2 = UIControl.alloc.init | |
sub2.when(UIControlEventTouchUpInside) do |
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
Steve Wozniak, Apple alumni and all-around amazing person - @stevewoz | |
Victor Agreda, Jr., TUAW - @superpixels | |
Mike T. Rose, TUAW - @miketrose | |
John Gruber, Daring Fireball - @gruber | |
Arnold Kim, MacRumors - @arnoldkim | |
Jason Snell, Macworld - @jsnell | |
Josh Lowensohn, CNET - @josh | |
Chris O'Brien, LA Times - @obrien | |
Mark Gurman, 9to5Mac - @markgurman | |
Matthew Panzarino, TNW - @panzer |
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
UI- and App Frameworks Evangelist - Jake Behrens, behrens@apple.com, twitter: @Behrens | |
- What's new in Cocoa | |
- Accessibility in iOS | |
- Building User Interfaces for iOS 7 | |
- Getting Started with UIKit Dynamics | |
- What's new in Cocoa Touch | |
- What's New With Multitasking | |
- Best Practices for Cocoa Animation | |
- Improving Power Efficiency with App Nap | |
- Introducing Text Kit |
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
#In Rakefile, set something like app.interface_orientations = [:portrait, :landscape_left, :landscape_right] | |
class AppDelegate | |
def application(application, didFinishLaunchingWithOptions:launchOptions) | |
application.setStatusBarStyle(UIStatusBarStyleBlackOpaque, animated:true) | |
@window = UIWindow.alloc.initWithFrame(UIScreen.mainScreen.bounds) | |
@window.rootViewController = NavigationController.alloc.initWithRootViewController(PortraitViewController.alloc.init) | |
@window.makeKeyAndVisible | |
true | |
end |
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
#!/bin/bash | |
killall Messages | |
killall Dock | |
open -a Messages |