Java Code Examples for android.widget.ListView.setSmoothScrollbarEnabled()

The following are Jave code examples for showing how to use setSmoothScrollbarEnabled() of the android.widget.ListView class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
+ Save this method
Example 1
Project: thingplug-app-android   File: SensorListActivity.java   View Source Code Vote up 5 votes
@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_sensor_list);

        listView = (ListView) findViewById(R.id.listView);
//        View footer = getLayoutInflater().inflate(R.layout.listview_footer, null, false) ;

        listView.setSmoothScrollbarEnabled(true);
        // header view
        contentView = getLayoutInflater().inflate(R.layout.listview_header, null, false);
        listView.addHeaderView(contentView);
        content = (TextView) findViewById(R.id.content);

        // listView에 header, footer 추가.
//        listView.addHeaderView(contentView) ;

        userInfo = UserInfo.getInstance(this);

        ActionBar bar = getSupportActionBar();
        bar.setTitle(getString(R.string.actionbar_list) + " (" + userInfo.loadDeviceID() + ")");

        oneM2MWorker = OneM2MWorker.getInstance();
        oneM2MWorker.setStateListener(new OneM2MWorkerListener());

        googleDriveHandler = new GoogleDriveHandler(this, new GoogleDriveCommandListener());
        //googleDriveHandler.connect();

//        deviceInfo = new SensorInfo(SensorType.DEVICE);
        oldTransferInterval = userInfo.loadTransferInterval();

        // create sensor list
        createSensorList();
    }