WEB开发网
开发学院手机开发Android 开发 通过改写ArrayAdapter 用AutoCompleteTextView 实... 阅读

通过改写ArrayAdapter 用AutoCompleteTextView 实现汉字和拼音双向关联

 2010-07-15 20:43:00 来源:WEB开发网   
核心提示:* @param context The current context.* @param textViewResourceId The resource ID for a layout file containing a TextView to use when* instantiating views.*/publ

* @param context The current context.

* @param textViewResourceId The resource ID for a layout file containing a TextView to use when

* instantiating views.

*/

public CityAdapter(Context context, int textViewResourceId) {

init(context, textViewResourceId, 0, new ArrayList(),new ArrayList());

}

/**

* Constructor

*

* @param context The current context.

* @param resource The resource ID for a layout file containing a layout to use when

* instantiating views.

* @param textViewResourceId The id of the TextView within the layout resource to be populated

*/

public CityAdapter(Context context, int resource, int textViewResourceId) {

init(context, resource, textViewResourceId, new ArrayList(),new ArrayList());

}

/**

* Constructor

*

* @param context The current context.

* @param textViewResourceId The resource ID for a layout file containing a TextView to use when

* instantiating views.

* @param objects The objects to represent in the ListView.

* @param objects2 城市拼音数组

*/

public CityAdapter(Context context, int textViewResourceId, T[] objects,T[] objects2) {

init(context, textViewResourceId, 0, Arrays.asList(objects),Arrays.asList(objects2));

}

/**

* Constructor

*

* @param context The current context.

* @param resource The resource ID for a layout file containing a layout to use when

* instantiating views.

* @param textViewResourceId The id of the TextView within the layout resource to be populated

* @param objects The objects to represent in the ListView.

*/

public CityAdapter(Context context, int resource, int textViewResourceId,

上一页  1 2 3 4 5 6 7  下一页

Tags:通过 改写 ArrayAdapter

编辑录入:coldstar [复制链接] [打 印]
赞助商链接