Fixed numerous memory management issues and possible crashers.

I resolved most of the analyzer warnings in Xcode and cleaned up the memory management of some classes. There were a few places that were assigning objects to properties without correct calls to -retain.

I also resolved some possible crashers with registering for KVO notifications in swizzled classes. Without unregistering for these notifications prior to the destruction of the swizzled object, Foundation will throw an exception.