Develop
2013.04.23 16:32
[android] ArrayAdapter 테스트 파일 ㅎㅎ
조회 수 45286 댓글 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(); } }); } }
-
[c] 게임 AI FSM 테스트 샘플 소스.. 꽤 괜찮은 소스..
-
[c] 관계형 연산자에 대한 설명
-
[c] 연산자 우선순위.. ㅋㅋ
-
[java] 파일 라인수 계산하는 프로그램 (하위 디렉토리까지..)
-
[php] 서버 이상 체크 해서 문자보내는 샘플소스..
-
[linux] crond 사용법.. ㅋㅋ
-
[php] 자주 쓰는 PHP 함수와 예제
-
아파치(Apache) 인증사용(htaccess)으로 특정 디렉토리에 암호걸기
-
[c][php] 프로세스정보와 메모리 정보 웹으로 출력하는거..
-
[c] 마우스 따라다니는 고양이 - 네코95 (WinAPI)
-
[c] 테트리스3D (Tetris 3D)
-
[c][cpp] mfc, win32api, 예제 소스 대박 모음~