Toaster icon indicating copy to clipboard operation
Toaster copied to clipboard

Add helper function for setting cornerRadius

Open cozzin opened this issue 5 years ago • 2 comments

Fix https://github.com/devxoul/Toaster/issues/113 Just add a setter for cornerRadius.
Actually, I have tried to make public backgroundView, but it does not work.

cozzin avatar Aug 29 '19 16:08 cozzin

I'm not a fan of this. In case of ambiguity, there is certainly a way to specify which method is the desired one. And solving the ambiguity for calling our method will not solve the ambiguity when you want to call the UIView method. It's better to remove cornerRadius entirely as I wrote in #113

Coeur avatar Sep 07 '19 13:09 Coeur

@Coeur I know you want to make backgroundView as pulbic, but it does not work when I tested.

I tested like this:

ToastView.appearacne().backgroundView.layer.cornerRadius = 20

Or did you mean like this code?

ToastView.appearacne().backgroundView = CustomBackgroundView()

cozzin avatar Sep 08 '19 08:09 cozzin