Last active
December 19, 2015 03:39
Revisions
-
troyharris renamed this gist
Aug 4, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
troyharris renamed this gist
Aug 4, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
troyharris created this gist
Jun 29, 2013 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,33 @@ // THGridMenuItem+ProjectItem.h #import "THGridMenuItem.h" #import "Project.h" @interface THGridMenuItem (ProjectItem) @property (nonatomic, strong) Project *project; -(Project *)project; -(void)setProject:(Project *)project; @end // THGridMenuItem+ProjectItem.m #import "THGridMenuItem+ProjectItem.h" #import <objc/runtime.h> static char projectMenuItemKey; @implementation THGridMenuItem (ProjectItem) -(Project *)project { return objc_getAssociatedObject(self, &projectMenuItemKey); } -(void)setProject:(Project *)project { objc_setAssociatedObject(self, &projectMenuItemKey, project, OBJC_ASSOCIATION_RETAIN_NONATOMIC); } @end