Develop
2013.04.23 16:32
[android] ArrayAdapter 테스트 파일 ㅎㅎ
조회 수 45242 댓글 0
ArrayAdapter 샘플 코드
public class ArrayAdapterTest2 extends ListActivity { ArrayList<String> aList = new ArrayList<String>(); public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); for(int i=0; i<100; i++){ aList.add("haha"+i); } ArrayAdapter<String> aA = new ArrayAdapter<String>(this, R.layout.list_item, aList); setListAdapter(aA); ListView lv = getListView(); lv.setTextFilterEnabled(true); lv.setOnItemClickListener(new OnItemClickListener() { public void onItemClick(AdapterView<?> parent, View view, int position, long id) { // When clicked, show a toast with the TextView text Toast.makeText(getApplicationContext(), ((TextView) view).getText(), Toast.LENGTH_SHORT).show(); } }); } }
번호 | 분류 | 제목 | 글쓴이 | 날짜 | 조회 수 |
---|---|---|---|---|---|
1137 | Etc | 양성/음성 오류에 대한 개념 | hooni | 2013.04.23 | 19853 |
1136 | Algorithm | 암호 알고리즘 및 프로토콜의 이해.. | hooni | 2013.04.23 | 17209 |
1135 | Develop | 알고리즘 성능분석 | hooni | 2014.06.24 | 2966 |
1134 | Develop | 알고리즘 성능 분석 기준 | hooni | 2014.06.24 | 2786 |
1133 | System/OS | 아파치(Apache) 인증사용(htaccess)으로 특정 디렉토리에 암호걸기 | hooni | 2013.04.23 | 13659 |
1132 | Etc | 아이폰의 터치스크린 정확도 | hooni | 2015.04.01 | 1419 |
1131 | Develop | 아이 훌레시 작업중 ㅋㅋ | hooni | 2013.08.09 | 0 |
1130 | Etc | 아두이노 관련 정보.. | hooni | 2013.04.23 | 21770 |
1129 | Etc | 스파이웨어(BHO) 탐지하는 방법.. | hooni | 2013.04.23 | 44409 |
1128 | Algorithm | 스터디 자료, 암호화에 대해서.. 나중에 볼 ppt.. | hooni | 2013.04.23 | 13371 |
1127 | Etc | 스마트폰 보안 해외 발생 사례~ | hooni | 2013.04.23 | 24939 |
1126 | Etc | 수리통계학 : 표본공간과 사상-1 | hooni | 2015.04.20 | 902 |