用作:
citySpinner=(Spinner) findViewById(R.id.cityspinner);
ArrayAdapter<CharSequence> cityadapter = ArrayAdapter.createFromResource(this, R.array.beijing_city, R.layout.spinner_item);
cityadapter.setDropDownViewResource(R.layout.spinner_down_item);
citySpinner.setAdapter(cityadapter);
my spinner_down_item.xml is:
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
android:background="@drawable/spinner_textview_rounded_corners"
android:id="@+id/text1"
android:textColor="#ffff0000"
android:gravity="center"
android:singleLine="true"
android:layout_width="fill_parent"
android:layout_height="40dip"
android:ellipsize="marquee" />
但dropDownView为:http://i.stack.imgur.com/S2dcA.jpg 你可以看到有一个默认的白色矩形边框在最外层,我的问题是如何删除它而不显示scrollbar.thank you