Call to delegate during dealloc process of the superview causes  crash, this fix uses the weak feature to nil out the reference during the dealloc process.
Merge pull request #35 from ahalls/master

Fix to delegate declaration.