Code example for ScrollView

Methods: fullScroll

0
	public void onClick(View v) {
		if (v == scrollStart){
			scroller.fullScroll(ScrollView.FOCUS_UP);
		} 
		else if (v == scrollEnd){
			scroller.fullScroll(ScrollView.FOCUS_DOWN);
		} 
	} 
	 
	private long lastIdle = 0;
	private long lastCPU = 0;
	 
	private float readUsage() { 
	    try { 
	        RandomAccessFile reader = new RandomAccessFile("/proc/stat", "r");
	        String load = reader.readLine();
 
	        String[] toks = load.split(" ");
 
	        long idle1 = Long.parseLong(toks[5]);
	        long cpu1 = Long.parseLong(toks[2]) + Long.parseLong(toks[3]) + Long.parseLong(toks[4])