开发者

Showing value of UISlider inside App Prefs?

开发者 https://www.devze.com 2022-12-18 11:35 出处:网络
I have a settings bundle, working perfectly, that I would like to customize a bit. I have, among other things, a PSSliderSpecifier and a PSTitleValueSpecifier.

I have a settings bundle, working perfectly, that I would like to customize a bit. I have, among other things, a PSSliderSpecifier and a PSTitleValueSpecifier.

What I would like to do is change the value of the PSTitleValueSpecifier to show the current value of the slider, preferably updating every time the slider's value changes (Actually, what I'd like even more would be displaying the slider's value on the same row as开发者_如何学JAVA the slider).

I know the settings bundle is rather strict about what you're allowed to do in it, but is there any way of doing this?


I don't know much about the Settings app stuff, but if you put the preferences in your own app and used a UISlider, it's very easy. Just add a UILabel next to it, and respond to the UISlider's valueChanged with a method that gets the UISlider's value and sets it as the text of the UILabel.

0

精彩评论

暂无评论...
验证码 换一张
取 消