本文共 297 字,大约阅读时间需要 1 分钟。
获取GPS功能是否禁用:
mgr=(LocationManager)getSystemService(LOCATION_SERVICE);
if(mgr.isProviderEnabled((android.location.LocationManager.GPS_PROVIDER ))) Toast.makeText(TestActivity.this,"gps enable", Toast.LENGTH_SHORT).show(); else Toast.makeText(TestActivity.this,"gps dis", Toast.LENGTH_SHORT).show();转载地址:http://hzpg.baihongyu.com/