TomThorpe / TTRangeSlider

A slider, similar in style to UISlider, but which allows you to pick a minimum and maximum range.
MIT License
968 stars 204 forks source link

Issue 61: Feature request: Shadow support for handles #91

Closed redcapua closed 5 years ago

redcapua commented 5 years ago

Issue #61 Feature request: Shadow support for handles

TomThorpe commented 5 years ago

Thanks for this!

Just wanted to check, what’s the purpose of removing the left handle from the superview then adding the right handle back (twice) in the opacity and radius methods?

Thanks! Tom

redcapua commented 5 years ago

That was a typo. Sorry for that :(

TomThorpe commented 5 years ago

No problem at all! :-)

But I just mean the [self.leftHandle removeFromSuperlayer]; , [self.layer addSublayer:self.leftHandle]; and [self.layer addSublayer:self.rightHandle]; lines entirely. I'm just wondering why they need to be there? Or if they can be removed entirely?

I dont think it should be needed to remove the handles from the superview and re-add them after the change? I've just tried checking out your branch and removing those lines completely and it still seemed to work fine - so I was just wondering if I had missed a reason for them being there?

Thanks again for your contribution :-)

redcapua commented 5 years ago

I dont think it should be needed to remove the handles from the superview and re-add them after the change?

It is a habit :) Remove object from view before changing to avoid conflict in the future changes.

In any case it is your repository, and your rules :)

TomThorpe commented 5 years ago

Gotcha. Yeah I think it's best to remove those lines if you dont mind, then we can get this merged! πŸ‘

redcapua commented 5 years ago

Sure! Will do and push update

2018-12-05 0:08 GMT+02:00, Tom Thorpe notifications@github.com:

Gotcha. Yeah I think it's best to remove those lines if you dont mind, then we can get this merged! πŸ‘

--

You are receiving this because you authored the thread.

Reply to this email directly or view it on GitHub:

https://github.com/TomThorpe/TTRangeSlider/pull/91#issuecomment-444277734

--


Kind regards, Vlad

redcapua commented 5 years ago

Lines: [self.leftHandle removeFromSuperlayer]; have been removed.

TomThorpe commented 5 years ago

Thanks, but it was also the [self.layer addSublayer:self.leftHandle]; and [self.layer addSublayer:self.rightHandle] lines too! We don't need those either if we're never removing the layer. I maybe should've just annotated the changes :-)

redcapua commented 5 years ago

Removed:

    [self.layer addSublayer:self.leftHandle];
    [self.layer addSublayer:self.rightHandle];
TomThorpe commented 5 years ago

LGTM πŸ‘