     }
     var darkTextColor = UIColorFromHex(0x000000, alpha: 0.75)
     var lightTextColor = UIColorFromHex(0xffffff, alpha: 0.9)
+    
+    enum ActionType {
+        case Close, Cancel
+    }
     
     let baseHeight:CGFloat = 160.0
     var alertWidth:CGFloat = 290.0

    }
    
    func buttonTap() {
        closeView(true);
    }
    
    func addCancelAction(action: ()->Void) {

                    self.view.alpha = 0
                    }, completion: { finished in
                        if withCallback == true {
                            if let action = self.closeAction where source == .Close {
                                action()
                            }
                        }
                        self.removeView(withCallback, source: source)
                })
                
        })
    }
    
    func removeView(withCallback:Bool, source:ActionType = .Cancel) {
        isAlertOpen = false
        self.view.removeFromSuperview()
        if withCallback {
            if let action = self.cancelAction where source == .Cancel {
                action()
            }
        }
    }
    
