Image picker support
This branch is a testing ground for adding custom-image support as suggested in #29.
This is pretty broken right now given the "state" concept we implemented.
I can see why the new state stuff has broken this now I've had a look through the code. I reckon this would be quite a useful addition if it can be made to work with the new code.
Yeah I haven't lost hope for this yet.
A few solutions come to mind:
- New state stuff just has to go
- Heavy refactoring with if/else for state vs image.
- State could be refactored into different state types:
- HSV state
- Live state (used for custom images, and useful for debugging)
/ping @unixpickle
I guess the cleanest option is potentially no.3. That keeps the logic in the same class etc and should result in less changes to RSColorPickerView
If we made a state base class and then subclassed it for HSV and Live states that would possibly work. I'll look into it when I'm free.
Even an ~~interface~~/protocol might do the job. Edit: abstract/base class is probably better, as suggested.