eliotfowler/EFCircularSlider — pull request #23 by kenthumphries (2014-07-03 23:21:08+00:00)
Title: Major refactor of EFCircularSlider

Hi Eliot,

I started using your EFCircularSlider component - it's terrific, thank you! Something I'd been keeping an eye out for since many months. It helped me kick start a fun app using the slider to change the time.

As I started using your component I realised that I wanted to make it work with AutoLayout. Then I realised that I wanted to better understand how the class was working. As I result I took on a fairly major refactoring process. I even split out all the maths into a separate class to make the EFCircularSlider class something that didn't need to (firsthand) know about trigonometry!

I haven't done any open source work in the past, so when I started off I didn't follow the usual fork, modify, pull request path. Instead I did a whole lot of work on a private repository. I've FINALLY had some time on my hands, so wanted to Do The Right Thing and offer my changes back to you & the community. However my refactoring work was now out of date by about 7 commits.

As such I tried to recreate my work on a fork with the following atomic commits:
___
507d46c move existing EFCircularSlider into a 'legacy' placeholder class
96682ff dropped in my refactored EFCircularSlider & accompanying EFCircularTrig
d4590a5 Removed half finished 'outer' label feature that I started but didn't have time to finish
643a112 Ported commit 94dd521 made by ciotto on main branch after I did my refactoring
699de73 Ported commits b390cf5, 7661b21, 28db7f5, bb9f55a (where necessary) made by fatuhoku & ciotto on main branch after I did my refactoring
dd23c8c Add demo to show how it now (also) works with AutoLayout
2c2409c Removed 'legacy' EFCircularSlider class
___

It would be great if you would accept these changes into the main branch. I tried to preserve all existing functionality, except for the line displacement property as described in my commit 699de73 - I don't think it's necessary with the updated AutoLayout/initWithRadius property. I appreciate it's a big change though, and that my preferred style may not match your own. If there's something that confuses you....well then this refactoring has failed it's main mission of improving clarity & modifiability!

Please let me know what you think.

Thanks
Kent