是有可能使固定的RatingBar? [英] is it possible to make fixed ratingbar?

查看:132
本文介绍了是有可能使固定的RatingBar?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在从网上的评价,并希望展现等级的RatingBar。

I am getting rating from the web and want to show the rating by ratingbar.

但我的问题是的RatingBar的评价是,当我滑动的RatingBar变化。

But my problem is rating of ratingbar is changing when I slide a ratingbar.

我要的评级是固定的,不会被用户的触摸改变。

I want the rating is fixed and do not changed by user's touch.

是任何人能够限制的RatingBar的控制权?我该怎么办呢?

is anybody able to limit control of ratingbar? How can I do that?

推荐答案

使用<一个href="http://developer.android.com/reference/android/widget/RatingBar.html#attr_android%3aisIndicator"><$c$c>android:isIndicator="true"在布局或<一href="http://developer.android.com/reference/android/widget/RatingBar.html#setIsIndicator%28boolean%29"><$c$c>setIsIndicator(boolean isIndicator) 从code与的RatingBar部件prevent用户交互。

Use android:isIndicator="true" in your layout or setIsIndicator(boolean isIndicator) from code to prevent user interaction with the RatingBar widget.

从文档报价:

安卓isIndicator - 无论这个等级吧应该只是一个指标(因此   用户不可更改)。

android:isIndicator - Whether this rating bar should only be an indicator (thus non-changeable by the user).

这篇关于是有可能使固定的RatingBar?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆