¡@

Home 

2014/10/15 ¤U¤È 10:16:13

iphone Programming Glossary: zspropertywatcher

When does an associated object get released?

http://stackoverflow.com/questions/6039309/when-does-an-associated-object-get-released

method and swizzle back the original in order to call up to it. That gets really messy though. The point of the ZSPropertyWatcher class is that KVO requires a standard callback method and I don't want to replace UIImageView's in case it uses one itself... zsFrameChanged self zsShowSpinner self.image void zsImageChanged self zsShowSpinner self.image BOOL showLoadingSpinner ZSPropertyWatcher imageWatcher ZSPropertyWatcher objc_getAssociatedObject self imageWatcherKey return imageWatcher nil void setShowLoadingSpinner.. self.image void zsImageChanged self zsShowSpinner self.image BOOL showLoadingSpinner ZSPropertyWatcher imageWatcher ZSPropertyWatcher objc_getAssociatedObject self imageWatcherKey return imageWatcher nil void setShowLoadingSpinner BOOL aBool ZSPropertyWatcher..