Last Updated: February 25, 2016
·
2.277K
· jirka8

Hide scrollbar in PhoneGap Android app (MainActivity.java)

package com.example.package;

import android.os.Bundle;
import org.apache.cordova.*;

public class MainActivity extends DroidGap {

@Override
public void onCreate(Bundle savedInstanceState) {       
    super.onCreate(savedInstanceState);
    super.loadUrl("file:///android_asset/www/index.html");      

    //hide scrollbar
    super.appView.setVerticalScrollBarEnabled(false);
    super.appView.setHorizontalScrollBarEnabled(false);
}

}