Like shopping?

Tuesday, February 23, 2010

Expandable lists and check boxes


I got another trivial question in a comment: how to add checkboxes to an expandable list view like this one? Nothing can be simpler, you just add CheckBox control to the child view that forms the row and that's it. Except that it does not work without some tweaks.You can download the example program from here. The first bizarre thing you can notice in res/layout/child_row.xml that the CheckBox is made non-focusable. Why to do that when we want the checkbox to capture

Convert Exif GPS info to Degree format on Android




In my own case; I have no digital camera with GPS, but I have a GPS logger. The GPS info can be added into JPG file using GPicSync. But it's in the format of degree, minute, second, not GeoPoint form, as I used in my Mapper exercise. So I have to convert it by myself. Here I create a class geoDegree to handle the conversion from degree, minute, second form to GeoPoint form.package com.AndroidExplorer;import android.media.ExifInterface;public class geoDegree {private boolean valid = false;Float


Android RatingBar




A RatingBar is an extension of SeekBar and ProgressBar that shows a rating in stars. The user can touch/drag or use arrow keys to set the rating when using the default size RatingBar. The smaller RatingBar style ( ratingBarStyleSmall) and the larger indicator-only style (ratingBarStyleIndicator) do not support user interaction and should only be used as indicators. main.xmlLINEARLAYOUT android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" >TEXTVIEW...

No comments:

Post a Comment