Skip to content

Instantly share code, notes, and snippets.

View hvsw's full-sized avatar
🏠
Working from home

Henrique Valcanaia hvsw

🏠
Working from home
View GitHub Profile
@hvsw
hvsw / DynamicTypeResponsive.swift
Created October 15, 2018 19:09 — forked from stevethomp/DynamicTypeResponsive.swift
Adds a simple way to register a view for automatic dynamic type updating by setting respondsToDynamicTypeChanges = true. Really only useful on iOS < 10
import Foundation
import ObjectiveC
// MARK: - DynamicTypeResponsive
protocol DynamicTypeResponsive {
var respondsToDynamicTypeChanges: Bool { get set }
}
extension UILabel: DynamicTypeResponsive {
var respondsToDynamicTypeChanges: Bool {
@hvsw
hvsw / iOS7-notifications.h
Created January 3, 2016 06:09 — forked from hpique/iOS7-notifications.h
List of all public notifications available in iOS 7.0 (or at least those whose constants are properly named).
// Developer/Library/Frameworks/SenTestingKit.framework/Headers/SenTestCaseRun.h
SENTEST_EXPORT NSString * const SenTestCaseDidStartNotification;
SENTEST_EXPORT NSString * const SenTestCaseDidStopNotification;
SENTEST_EXPORT NSString * const SenTestCaseDidFailNotification;
// Developer/Library/Frameworks/SenTestingKit.framework/Headers/SenTestDistributedNotifier.h
SENTEST_EXPORT NSString * const SenTestNotificationIdentifierKey;
// Developer/Library/Frameworks/SenTestingKit.framework/Headers/SenTestSuiteRun.h
SENTEST_EXPORT NSString * const SenTestSuiteDidStartNotification;