开发者

How to create slider same as android inbuilt lock slider? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers. 开发者_如何学Go

Want to improve this question? Update the question so it focuses on one problem only by editing this post.

Closed 9 years ago.

Improve this question

i need creating slider same as like iphone or android inbuilt lock slider in home screen app. for this functionality i will use any inbuilt control or create custom layout for this. anyone has info. regarding this than pls send me any link or details.


You will have to make a custom slider:

Use a seekbar widget.

Then, on the onStopTrackingTouch listener, reset the seekbar position to ZERO unless the rightmost value has been reached. This will have a "snapping" effect. You can also code an animation to bring it back to the initial position smoothly instead of the "snapping" effect. If the rightmost value has been reached, you can do whatever you wanted to do.

You can use custom 9-patch graphics too!

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜