Added support for finish/cancel on background view tapping.
Moved private API to protected header for easier subclassing.