Code example for ArrayAdapter

Methods: setAdapter

0
            "Move Logger Example", "Disable Touch Intercept"}; 
	 
	@Override 
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, ITEMS);
		getListView().setAdapter(adapter);
		getListView().setOnItemClickListener(this);
	} 
 
	@Override 
	public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
        switch (position) {
            case 0: //2D Scrolling 
                startActivity(new Intent(this, TwoDimensionScrollActivity.class));
                break; 
            case 1: //2D GestureDetector Scrolling 
                startActivity(new Intent(this, TwoDimensionGestureScrollActivity.class));
                break; 
            case 2: //Multi-Touch Image View 
                startActivity(new Intent(this, MultitouchActivity.class));