method:smoothScrollTo ( int x, int y )
return type:void
content:ใช้เลื่อน scroll แบบ smooth โดยจะเลื่อนไปยังตำแหน่ง x, y ที่กำหนด
example:public class AndroidBamboo extends Activity
{
public void onCreate( Bundle savedInstanceState )
{
super.onCreate ( savedInstanceState );
ScrollView scroll_view = new ScrollView ( this );
Button button = new Button ( this );
button.setText ( "Into BambooLabCode" );
ViewGroup.LayoutParams params = new ViewGroup.LayoutParams ( 100, 24 );
scroll_view.addView ( button, 0, params );
scroll_view.setSmoothScrollingEnabled ( true );
scroll_view.smoothScrollTo ( 0, 30 );
setContentView ( scroll_view );
}
}