FileDocCategorySizeDatePackage
GridInVertical.javaAPI DocAndroid 1.5 API1696Wed May 06 22:42:02 BST 2009com.android.frameworktest.gridview

GridInVertical

public class GridInVertical extends android.app.Activity
Exercises a grid in a vertical linear layout

Fields Summary
android.os.Handler
mHandler
android.widget.TextView
mText
android.widget.GridView
mGridView
Constructors Summary
Methods Summary
public android.widget.GridViewgetGridView()

        return mGridView;
    
public voidonCreate(android.os.Bundle icicle)


    
        
        super.onCreate(icicle);
        
        setContentView(R.layout.grid_in_vertical);

        String values[] = new String[1000];
        int i=0;
        for(i=0; i<1000; i++) {
            values[i] = ((Integer)i).toString();
        }
        
        mText = (TextView) findViewById(R.id.text);
        mGridView = (GridView) findViewById(R.id.grid);
        mGridView.setAdapter(new ArrayAdapter<String>(this,
                android.R.layout.simple_list_item_1, values));