mirror of
https://github.com/apache/cordova-android.git
synced 2025-03-16 08:21:04 +08:00
More comments
This commit is contained in:
parent
88127f0b20
commit
4ce3c33381
@ -37,6 +37,10 @@ public class PhoneGap {
|
|||||||
vibrator.vibrate(pattern);
|
vibrator.vibrate(pattern);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Android requires a provider, since it can fall back on triangulation and other means as well as GPS
|
||||||
|
*/
|
||||||
|
|
||||||
public void getLocation(String provider){
|
public void getLocation(String provider){
|
||||||
LocationManager locMan = (LocationManager) mCtx.getSystemService(Context.LOCATION_SERVICE);
|
LocationManager locMan = (LocationManager) mCtx.getSystemService(Context.LOCATION_SERVICE);
|
||||||
Location myLoc = (Location) locMan.getLastKnownLocation(provider);
|
Location myLoc = (Location) locMan.getLastKnownLocation(provider);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user