Customize Spinner

by Ajay » Wed, 21 Apr 2010 18:47:55 GMT

Sponsored Links
   I want to customize the spinner behavior a little bit. I want to
add a couple of buttons at the end of the drop down menu that is
displayed when the user selects the control. Any idea how this could
be done?

Thank you,


Customize Spinner

by Tim » Wed, 21 Apr 2010 19:03:40 GMT


Clone the spinner code in your project, then modify it.

By the way, why is the drop-down widget called Spinner, and the
spinner widget called NumberPicker? Confusing!


Sponsored Links

Customize Spinner

by Ajay » Wed, 21 Apr 2010 20:36:10 GMT

 Is there a simpler way or standard widget that I could use?

Thank you,


Customize Spinner

by Mark Murphy » Wed, 21 Apr 2010 20:43:31 GMT


Write your own Dialog (or a Dialog-themed Activity) to look how you
want. Make a "Spinner" out of TextViews and ImageButtons. When they
click the ImageButton, display the Dialog or Activity for the user

Mark Murphy (a Commons Guy)  | 

_The Busy Coder's Guide to Android Development_ Version 3.0


Other Threads

1. [Wta] Dell Venue

Saya baru tau bahwa dell venue pro (WP7) ternyata dah punya sodara bernama
dell venue (Froyo). Modelnya mirip banget, sama2 keren IMHO.

Udah ada yg coba? Infonya baru beredar di asia timur aja, hongkong dan


Sent from my StreakyDroid


2. How to get notified when layout is ready

How can I get notified when the layout is fully calculated? The short
answer is to attached a listener for a callback when the layout is
calculated. Here's what it looks like.

public void onCreate(Bundle savedInstanceState)
  RelativeLayout vMain = (RelativeLayout)
     this.getLayoutInflater().inflate(R.layout.main, null);
  new ViewTreeObserver.OnGlobalLayoutListener() {
    public void onGlobalLayout() {

public void DisplayLayoutDimensions()
  StringWriter sw = new StringWriter(1000);
  PrintWriter out = new PrintWriter(sw);
  TextView t = (TextView) findViewById(;
  ImageView img = (ImageView) findViewById(;
  out.printf("\nImage Drawable\n");
  out.printf("ImageView Height dp: %d\n", img.getHeight());
  out.printf("ImageView Measured Height dp: %\n",


3. Integration testing with mock content providers

4. Background image on a spanned portion of text in a TextView (how?)

5. Investigating layout problems in GridView

6. Force close help, my first app

7. Transaction Limit Google Geocoder & Maps