CRToast
CRToast copied to clipboard
Add option to set a custom view class.
This changeset enables the creation of custom layouts for notifications. I had to make a few things public that weren't before, namely the option defaults system and some parts of CRToastView
, but hopefully the extra functionality is worth it.
The reason that I made the CRToast
options/defaults public is because some of them are pretty necessary to create a good layout (e.g. displayUnderStatusBar
, text/fonts, etc).
If this is too much exposure, I could make client code keep track of this stuff itself, but the defaults would have to be duplicated since they currently aren't available from the outside.
Hmmm, I really wanna add this feature, but I was thinking more an opt in and bring your own view kinda thing or use the built in stuff. Kinda like UITableViewCell
. This would avoid exposing all these formerly private properties. This is pretty neat though and allows for the functionality of all the options to stay intact even when providing your own layout code. Gotta think on this one...
Guys, when you plan to marge this useful stuff?
Since @cruffenach has weighed in I don't want to jump the gun. It's up to him - once he has the time.
:+1: from me.
Any plans to merge this CR? I need exactly this in my project and may have to fork the repo if not provided.