How to make UISlider's “track” invisible?

前端 未结 8 639
感动是毒
感动是毒 2021-02-05 07:44

I\'m trying to emulate Apple\'s \"Slide to Unlock\" feature in my application. I get to this point (image below), but as you can see the UISlider\'s \"track\" is visible and is

8条回答
  •  礼貌的吻别
    2021-02-05 08:00

    Answer by @Arjay Waran is the best in my opinion.

    Heres the Swift 3.0 Version of it.

    slider.minimumTrackTintColor = UIColor.clear
    slider.maximumTrackTintColor = UIColor.clear
    

    Cheers

提交回复
热议问题