| | |
| | | @IBOutlet weak var view_container: UIView! |
| | | @IBOutlet weak var label_title: UILabel! |
| | | @IBOutlet weak var label_content: UILabel! |
| | | |
| | | @IBOutlet weak var btn_cancel: UIButton! |
| | | @IBOutlet weak var btn_complete: UIButton! |
| | | |
| | | private var title:String! |
| | | private var content:String! |
| | | private var clouse:((Bool)->Void)! |
| | |
| | | } |
| | | |
| | | |
| | | static func show(title:String,content:String, clouse:@escaping (Bool)->Void){ |
| | | static func show(title:String,content:String,isSingle:Bool = false, clouse:@escaping (Bool)->Void){ |
| | | let alertView = CommonAlertView.jq_loadNibView() |
| | | alertView.label_title.text = title |
| | | alertView.label_content.text = content |
| | | alertView.btn_cancel.isHidden = isSingle |
| | | alertView.clouse = clouse |
| | | alertView.frame = sceneDelegate?.window?.frame ?? .zero |
| | | sceneDelegate?.window?.addSubview(alertView) |
| | |
| | | } |
| | | } |
| | | |
| | | static func show(title:String,attribute:NSMutableAttributedString, clouse:@escaping (Bool)->Void){ |
| | | static func show(title:String,attribute:NSMutableAttributedString,isSingle:Bool = false, clouse:@escaping (Bool)->Void){ |
| | | let alertView = CommonAlertView.jq_loadNibView() |
| | | alertView.label_title.text = title |
| | | alertView.btn_cancel.isHidden = isSingle |
| | | alertView.label_content.attributedText = attribute |
| | | alertView.clouse = clouse |
| | | alertView.frame = sceneDelegate?.window?.frame ?? .zero |
| | |
| | | } |
| | | } |
| | | |
| | | override func layoutSubviews() { |
| | | super.layoutSubviews() |
| | | btn_complete.localGradientColor(cornerRadius: 20) |
| | | } |
| | | |
| | | |
| | | @IBAction func closeAction(_ sender: UIButton) { |
| | | UIView.animate(withDuration: 0.4) { |