Propriété de Albiri Sigue
customer 27921 at Fri Mar 11 19:19:45 +0100 2011
98 L’art du développement Android
RatingBar rate=null;
TextView label=null;
ViewWrapper(View base) {
this.base=base;
}
RatingBar getRatingBar() {
if (rate==null) {
rate=(RatingBar)base.findViewById(R.id.rate);
}
return(rate);
}
TextView getLabel() {
if (label==null) {
label=(TextView)base.findViewById(R.id.label);
}
return(label);
}
}
Les Figures 9.3 et 9.4 montrent ce qu’affiche cette application.
Figure 9.3
L’application
RateListDemo lors
de son démarrage.
Livre Android.book Page 98 Dimanche, 8. novembre 2009 12:23 12
Précédent

- 113/391

Suivant