CRToast icon indicating copy to clipboard operation
CRToast copied to clipboard

Options in swift CustomType

Open ylecuyer opened this issue 9 years ago • 1 comments

When using with swift there is an error when setting custom type:

let options = [ kCRToastNotificationTypeKey: CRToastType.Custom, kCRToastTextKey: "Good", kCRToastBackgroundColorKey: UIColor.init(red: 0, green: 0.67, blue: 0, alpha: 1), kCRToastNotificationPreferredHeightKey: 50, ]

We have to replace CRToastType.Custom by 2

let options = [ kCRToastNotificationTypeKey: 2, kCRToastTextKey: "Good", kCRToastBackgroundColorKey: UIColor.init(red: 0, green: 0.67, blue: 0, alpha: 1), kCRToastNotificationPreferredHeightKey: 50, ]

ylecuyer avatar Apr 03 '16 17:04 ylecuyer

@ylecuyer use CRToastType.Custom.rawValue

mixdesign avatar Apr 26 '16 08:04 mixdesign