 extension UIActivityIndicatorView: Spinner {
 
     // Called when the activity indicator should be removed.
-    public func dismiss() {
+    public func dismiss(enablesUserInteraction enablesUserInteraction: Bool = false) {
         stopAnimating()
         removeFromSuperview()
     }

        return view
    }

    public func dismiss() {
        if let button = spinner?.superview as? UIButton {
            button.userInteractionEnabled = true
            button.restoreTitleColors(controlTitleColors)
        }
        if let view = spinner?.superview {
            view.userInteractionEnabled = true
        }
        

	method, because the 'showInView' methods need to be custom for each class
 */
public protocol Spinner {
    
    /**
     Dismiss the Spinner. Implementations should remove any views from their superview.
     
     - Parameter enablesUserInteraction: A boolean that specifies if the user interaction on the view should be enabled when the spinner is dismissed
     */
    func dismiss(enablesUserInteraction enablesUserInteraction: Bool)
}

public extension Spinner {
    func dismiss(enablesUserInteraction enablesUserInteraction: Bool = false){}
}

public class SpinnerView: NSObject, Spinner {
