From e17e6e05c408e1b538a803a157558a4d51fc0614 Mon Sep 17 00:00:00 2001 From: Seyyed Parsa Neshaei Date: Wed, 7 Jul 2021 11:07:51 +0430 Subject: [PATCH] Fixing issue #477 - Add ability to show alert without icon --- SCLAlertView/SCLAlertView.swift | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/SCLAlertView/SCLAlertView.swift b/SCLAlertView/SCLAlertView.swift index bf85de5..b3f1fe7 100644 --- a/SCLAlertView/SCLAlertView.swift +++ b/SCLAlertView/SCLAlertView.swift @@ -31,7 +31,7 @@ fileprivate func > (lhs: T?, rhs: T?) -> Bool { // Pop Up Styles public enum SCLAlertViewStyle { - case success, error, notice, warning, info, edit, wait, question + case success, error, notice, warning, info, edit, wait, question, none public var defaultColorInt: UInt { switch self { @@ -51,6 +51,8 @@ public enum SCLAlertViewStyle { return 0xD62DA5 case .question: return 0x727375 + case .none: + return 0x000000 } } @@ -804,6 +806,9 @@ open class SCLAlertView: UIViewController { case .question: iconImage = checkCircleIconImage(circleIconImage, defaultImage:SCLAlertViewStyleKit.imageOfQuestion) + + case .none: + iconImage = nil } // Title