Android Chinese API (41) -- RatingBar. OnRatingBarChangeListener

Source: Internet
Author: User

 

Preface

This chapter is about android. widget. RatingBar. OnRatingBarChangeListener, version: Android 2.2 r1, translated from madgoat, welcome to his blog: http://madgoat.cn, thanks again madgoat! I look forward to your participation in Android API Chinese translation, contact me over140@gmail.com.

 

Statement

You are welcome to repost, but please keep the original source of the article :)

Blog Garden: http://www.cnblogs.com/

Android Chinese translation group: http://www.cnblogs.com/over140/

 

Body

I. Structure

    Public static interface RatingBar. OnRatingBarChangeListener

 

Ii. Overview

Notify the client of the callback function when the rating level changes. This includes changes triggered by a user through gestures, direction keys, or trackballs, and changes triggered by programming.

 

Iii. Public Methods

Public abstract void onRatingChanged (RatingBar ratingBar, float rating, boolean fromUser)

The notification rating has been modified. The client can use the fromUser parameter to distinguish between user-triggered changes and programming-triggered changes. When you drag a user, the user will not be called continuously, but will be called only when the user finally leaves the touch to end the score.

Parameters

RatingBar

Rating current score. The value range is 0 to the number of stars.

FromUser returns true if the score change is triggered by the movement of the user's touch gesture or direction key trackball.

 

 

4. Related Articles

Android Chinese API (40) -- RatingBar

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.