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
// MARK: - Darwin Notifications | |
static private let defaultsOnPhoneChangedDarwinNotificationName = "UserDefaultsOnPhoneDidChangeDarwinNotification" | |
static private let defaultsOnWatchChangedDarwinNotificationName = "UserDefaultsOnWatchDidChangeDarwinNotification" | |
static var notificationNameForReceiving: String? | |
static var notificationNameForSending: String? | |
/// Sets up the broadcast and receiving darwin notification names as well as | |
/// as the necessary observer callbacks. |
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
// | |
// Copyright (c) 2015 Nexar Inc. - All Rights Reserved. Proprietary and confidential. | |
// | |
// Unauthorized copying of this file, via any medium is strictly prohibited. | |
import Foundation | |
import Mixpanel | |
public class Tweaks : NSObject, MPTweakObserver { | |
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
/** | |
* Levenshtein edit distance calculator | |
* Usage: levenstein <string> <string> | |
* | |
* Inspired by https://gist.github.com/bgreenlee/52d93a1d8fa1b8c1f38b | |
* Improved with http://stackoverflow.com/questions/26990394/slow-swift-arrays-and-strings-performance | |
*/ | |
class Tools { |
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
UIFontDescriptor *fontDescriptor = [UIFontDescriptor fontDescriptorWithFontAttributes:@{ | |
UIFontDescriptorNameAttribute: @"SourceSansPro-Regular", | |
UIFontDescriptorCascadeListAttribute: | |
@[ | |
[UIFontDescriptor fontDescriptorWithFontAttributes:@{ UIFontDescriptorNameAttribute: @"Hiragino Sans GB W3" }] | |
] | |
}]; | |
}); | |
UIFont *font = [UIFont fontWithDescriptor:fontDescriptor size:pointSize]; |
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
// | |
// SlideAnimatedTransitioning.h | |
// SwipeLeft | |
// | |
// Created by Visnu on 4/14/14. | |
// Copyright (c) 2014 Visnu Pitiyanuvath. All rights reserved. | |
// | |
#import <Foundation/Foundation.h> |
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
@interface NSObject (Debounce) | |
- (void)debounce:(SEL)action delay:(NSTimeInterval)delay; | |
@end |
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
// UIInterfaceOrientationMask vs. UIInterfaceOrientation | |
// As far as I know, a function like this isn't available in the API. I derived this from the enum def for | |
// UIInterfaceOrientationMask. | |
inline BOOL OrientationMaskSupportsOrientation(UIInterfaceOrientationMask mask, UIInterfaceOrientation orientation) { | |
return (mask & (1 << orientation)) != 0; | |
} |
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)layoutSubviews{ | |
[super layoutSubviews]; | |
[UIView beginAnimations:nil context:NULL]; | |
[UIView setAnimationBeginsFromCurrentState:YES]; | |
[UIView setAnimationDuration:0.0f]; | |
for (UIView *subview in self.subviews) { |
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
''' | |
Steps: | |
1. Create any milestones | |
2. Create any labels | |
3. Create each issue, linking them to milestones and labels | |
3.1: Update status for new issue if closed | |
4: Create all the comments for each issue | |
''' | |
import getpass | |
import json |
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
// | |
// NSObject+Blocks.h | |
// Filemator | |
// | |
// Created by Zachary Waldowski on 4/12/11. | |
// Copyright 2011 Dizzy Technology. All rights reserved. | |
// | |
@interface NSObject (Blocks) |
NewerOlder