Skip to content

Instantly share code, notes, and snippets.

@zuccoi
zuccoi / RLRAppearanceForwarding.h
Created March 26, 2014 11:33
Mix-in protocol that forwards appearance methods to child view controllers
/*
RLRAppearanceForwarding.h
Copyright ©2014 Kazki Miura. All rights reserved.
*/
#import <UIKit/UIKit.h>
@protocol RLRAppearanceForwarding <NSObject>
@zuccoi
zuccoi / RLRTableViewCellSelectionDuringInteractivePopAndPush.h
Last active August 29, 2015 13:57
Mix-in protocol that keeps selected table view cell during interactive pop
/*
RLRTableViewCellSelectionDuringInteractivePopAndPush.h
Copyright ©2014 Kazki Miura. All rights reserved.
*/
#import <UIKit/UIKit.h>
@protocol RLRTableViewCellSelectionDuringInteractivePopAndPush
@zuccoi
zuccoi / NSObject+RLTraverse.h
Created October 6, 2012 01:20
Category methods to traverse object graph and view tree.
#import <Foundation/Foundation.h>
// RLTraverseObjectGraphBlock
typedef void (^RLTraverseObjectGraphBlock)(id obj, NSUInteger depth, NSUInteger idx, id parent, BOOL *stop); // If you want to stop traversing completely, set YES to *stop.
// RLChildrenGetter
typedef id (^RLChildrenGetter)(id obj, NSUInteger depth, NSUInteger idx, id parent); // Return object which responds to enumerateObjetsUsingBlock: method. If you don't want to dive deeper, return nil.
@interface NSObject (RLTraverse)