Android判断gps是否打开

来源:互联网 发布:head first python 2 编辑:程序博客网 时间:2024/06/06 06:57
        LocationManager lm = (LocationManager) this.getSystemService(Context.LOCATION_SERVICE);
        boolean gpsEnabled = lm.isProviderEnabled(LocationManager.GPS_PROVIDER);
0 0