summaryrefslogtreecommitdiffstats
path: root/location/java
Commit message (Collapse)AuthorAgeFilesLines
* Remove unused imports from frameworks/base.John Spurlock2013-11-201-1/+0
| | | | Change-Id: Ia1f99bd2c1105b0b0f70aa614f1f4a67b2840906
* Improve some javadoc related to isProviderEnabled() apisTom O'Neill2013-09-111-6/+12
| | | | | | | | - LocationManager.isProviderEnabled() no longer throws SecurityException: the caller could already circumvent the permission check by calling Secure.isLocationProviderEnabled() Change-Id: I5abd04264299671ed35ce4594b5be46d86378767
* Incorporate new API council commentsTom O'Neill2013-09-051-85/+86
| | | | | | | | | | | | | | | | | | | | - Split getStatus() into onGetSummary() and onGetEnabled() - Call them on app's UI thread - Allow runtime exceptions to propagate up - Make a couple of more methods final to prevent subclasses from playing around with the intent - Remove explicit timing requirement from javadoc - Mention that this will be restricted to system-image apps (will be enforced by the actual settings code) - b/10461474 Change-Id: Id22dd7a707c05de396ae4c5810e839ca734714c0
* Add LocationManager.MODE_CHANGED_ACTION broadcastTom O'Neill2013-09-031-1/+13
| | | | | | | | | - Currently redundant with PROVIDERS_CHANGED_ACTION, but that may change in the future - Part of fix for b/10409275 Change-Id: I12daaf20e6546fd9e9dc71c599967fa0ad95e27f
* Improve constant names for settings injection APITom O'Neill2013-08-301-38/+56
| | | | | | | | - Add timing for getStatus() call to encourage implementors to be fast - Affects b/10461474 Change-Id: I503cbae5cf27008c587a39ab4e60d8e09daedecc
* Remove or reduce visibility of deprecated methodsTom O'Neill2013-08-271-20/+1
| | | | | | | | | | | | | | | - Fix additional getInt() path, restores the location settings screen functionality. - Should fix "unresolved link" build breakages in git_klp-dev-plus-aosp-without-vendor, which is much more persnickety than klp-dev for some reason. - Add warning that we may add additional location modes in the future. - Finish fix for b/10461763 and b/10461474 Change-Id: Id7155e3a0d7526a377d446018ef3bdb057bad3a6
* Address API Review for SettingInjectorServiceTom O'Neill2013-08-261-28/+66
| | | | | | | | | | | | | | | | | | | | | | | - Escape < and > in javadoc - Constructor does not take log tag - Start intent rename - Comments for Status.summary and enabled - Bonus fixes: - Start renaming STATUS_KEY to SUMMARY_KEY - Send message back even if getting the status fails so we don't have to wait for the fetch to time out - Add comment about setting activity being invoked when disabled - Partial fix for b/10461474 Change-Id: I025e7e0782c2873a4eda20ab4793bc6145daf8db
* Add a little comment about the enabled valueTom O'Neill2013-08-221-1/+8
| | | | Change-Id: I4ac0b864f55992242b6a3b0d8ffb328f23f6b645
* Warn that SettingInjectorService must be fastTom O'Neill2013-08-191-0/+12
| | | | | | - Move UPDATE_INTENT to SettingInjectorSErvice Change-Id: I9c8f8dc0878647a051cb852721b3436e9d55b391
* Add comments to new hidden API in LocationRequest.David Christie2013-08-161-2/+24
| | | | | | | Document their purpose and permissions required in case this is unhidden in a different code line. Change-Id: I42f6f950157f488cf51b361e3411861ff98794e8
* Merge "Use default class loader when creating a LocationRequest from Parcel. ↵David Christie2013-08-161-1/+1
|\ | | | | | | This seems to be the standard usage, and there are rare reports of requestLocationUpdates giving NullPointerExceptions on the first call to requestLocationUpdates but not on subsequent calls (b/10207898)." into klp-dev
| * Use default class loader when creating a LocationRequest from Parcel.David Christie2013-08-151-1/+1
| | | | | | | | | | | | | | | | This seems to be the standard usage, and there are rare reports of requestLocationUpdates giving NullPointerExceptions on the first call to requestLocationUpdates but not on subsequent calls (b/10207898). Change-Id: If7a873fba5a2cd77b836ff3fda89105da20104ac
* | Ensure LocationRequest's worksource defaults to nullDavid Christie2013-08-161-1/+1
|/ | | | | | | | Helps to make sure the service doesn't throw a SecurityException for not having the UPDATE_DEVICE_STATS permission. Change-Id: I9be0302f1378d2c4441e6b7d5ce472ed0d5fbd80
* Merge "API for location settings injection" into klp-devTom O'Neill2013-08-141-0/+181
|\
| * API for location settings injectionTom O'Neill2013-08-131-0/+181
| | | | | | | | | | | | - Partial fix for b/10287745 Change-Id: Ie998ce0a7b350e4183fce5753bfac3eb51238ff4
* | Add support in the platform for Flp Geofencing.destradaa2013-08-131-8/+8
|/ | | | Change-Id: I0fb0e276d3a06322697bb5d46323779aca1f78c5
* Add FlpHal layer to support Location Batching.destradaa2013-08-084-0/+279
| | | | Change-Id: Ia3a57d869dfb3f067a1b95fa66d54f311ddcfdc3
* Update gps status icon to be a "high power" location icon.David Christie2013-08-081-0/+11
| | | | | | | Move icon to right side of the screen and synchronize status with AppOpsManager.OP_MONITOR_HIGH_POWER_LOCATION. Change-Id: Iea2570501cb18be0489669fd4ea240dc63f9567a
* Allow a particular LocationRequest to be excluded fromDavid Christie2013-08-011-0/+14
| | | | | | | AppOps monitoring as long as the client as the appropriate permission (UPDATE_DEVICE_STATS). Change-Id: I7223a53bc1551e6498302a22eb310c8c5b5684b0
* Add WorkSource capability to LocationManagerDavid Christie2013-07-221-0/+16
| | | | Change-Id: I0fbbad0879b87ecc75a503bf7963356595bf4b96
* am 39069b6e: am efb3726c: am 2b8f3734: am e3c549fc: am cd70c873: Merge ↵Joe Malin2013-05-131-2/+13
|\ | | | | | | | | | | | | "Android U: Making Apps Location-Aware" into jb-mr1.1-docs * commit '39069b6e82fa848608d56b4efc8f28785816fe27': Android U: Making Apps Location-Aware
| * am efb3726c: am 2b8f3734: am e3c549fc: am cd70c873: Merge "Android U: Making ↵Joe Malin2013-05-131-2/+13
| |\ | | | | | | | | | | | | | | | | | | Apps Location-Aware" into jb-mr1.1-docs * commit 'efb3726c226001149c92d48fa50da7031c231490': Android U: Making Apps Location-Aware
| | * Android U: Making Apps Location-AwareJoe Malin2013-05-131-2/+13
| | | | | | | | | | | | Change-Id: I8f44c6ca6d797ceb8ada5b2c723a8cca0081cf0a
* | | GPS Hardware geofencing.Jaikumar Ganesh2013-04-102-0/+61
| | | | | | | | | | | | | | | | | | Add support for doing geofencing in hardware. Change-Id: I6d5015190e8d84e1f4beb1010ed977a71c1622d0
* | | Annotate Locations coming from mock providersVictoria Lease2013-01-222-3/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | LocationManagerService now annotates incoming Location objects that have come from mock location providers. The new isFromMockProvider() method can be called on any Location to determine whether the provider that supplied the Location was a mock location provider. Bug: 6813235 Change-Id: Ib5140e93ea427f2e0b0036151047f87a02b4d23a
* | | New "app ops" service.Dianne Hackborn2013-01-092-3/+3
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Initial implementation, tracking use of the vibrator, GPS, and location reports. Also includes an update to battery stats to also keep track of vibrator usage (since I had to be in the vibrator code anyway to instrument it). The service itself is only half-done. Currently no API to retrieve the data (which once there will allow us to show you which apps are currently causing the GPS to run and who has recently accessed your location), it doesn't persist its data like it should, and no way to tell it to reject app requests for various operations. But hey, it's a start! Change-Id: I05b8d76cc4a4f7f37bc758c1701f51f9e0550e15
* | am 4b77660b: am 7023b3b0: Merge "clarify Geofence.createCircle() param ↵Victoria Lease2012-11-291-2/+2
|\ \ | |/ | | | | | | | | | | ranges" into jb-mr1.1-dev * commit '4b77660b38cfff2ffb67c15db4c9e20adaac41d7': clarify Geofence.createCircle() param ranges
| * clarify Geofence.createCircle() param rangesVictoria Lease2012-11-271-2/+2
| | | | | | | | | | | | | | | | This commit adds the valid ranges to the latitude/longitude parameters in Geofence.createCircle()'s javadoc. Bug: 7172696 Change-Id: Iff6e3c3723d3fd9b6393bbc827ec5755c0d034af
* | am 768d9e1a: Merge "Correct executable bit for source files"Kenny Root2012-11-073-0/+0
|\ \ | |/ |/| | | | | * commit '768d9e1a72ceee7d4a5f608776b87b62d6ce4a04': Correct executable bit for source files
| * Correct executable bit for source filesKenny Root2012-11-073-0/+0
| | | | | | | | | | | | | | | | | | Many media files and source code files were marked as executable in Git. Remove those. Also a shell script and python script were not marked as executable. Change-Id: Ieb51bafb46c895a21d2e83696f5a901ba752b2c5
| * DO NOT MERGE. Add package-name-prefix blacklist for location updates.Nick Pelly2012-07-302-13/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Settings.Secure value locationPackagePrefixBlacklist and locationPackagePrefixWhitelist contains comma seperated package-name prefixes. Location & geo-fence updates are silently dropped if the receiving package name has a prefix on the blacklist. Status updates are not affected. All other API's work as before. A content observer is used so run-time updates to the blacklist apply immediately. There is both a blacklist and a whitelist. The blacklist applies first, and then exemptions are allowed from the whitelist. In other words, if your package name prefix matches both the black AND white list, then it is allowed. Change-Id: I4ea2ad56fa6bd75d32151bc250ac25c26a5777c4
* | Hide new location APIs and undeprecate old onesLaurent Tu2012-11-016-151/+26
| | | | | | | | | | | | | | | | | | Hide all new location APIs related to LocationRequest/Geofence and undeprecate all deprecated APIs consequently to the LocationRequest and Geofence introduction. Also introduce LocationRequestUnbundled for LocationProviders to use. Change-Id: I5b116c7d342041f45b341c88a4b6813571118018
* | Merge "fix NLP for COARSE applications, build FLP with SDK" into jb-mr1-devVictoria Lease2012-11-011-0/+8
|\ \
| * | fix NLP for COARSE applications, build FLP with SDKVictoria Lease2012-11-011-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In this commit, we provide a means for unbundled location providers to attach an EXTRA_NO_GPS_LOCATION to the Locations that they report. We also build FusedLocation against the SDK rather than the internal tree. Used in conjunction with I394ded497b8de40d1f85618bff282553cdf378cb to fix NLP for applications with only ACCESS_COARSE_LOCATION permission. Bug: 7453355 Change-Id: Ie696f7abff9ef5237740ab87fe9f537a1c812c54
* | | docs: Clarify the callback mechanisms for LocationRequestScott Main2012-11-012-2/+10
|/ / | | | | | | | | | | and clarify horizontal geofencing Change-Id: I8ff264d7a12c8ec3c79854e008aeeb5f922ad459
* | revise android.location.Geofence documentationVictoria Lease2012-10-241-3/+1
| | | | | | | | | | Bug: 7172696 Change-Id: Ib1a104ee4a97c51996200b8d456face66178115f
* | LocationManager javadoc permission fixesVictoria Lease2012-10-221-23/+9
| | | | | | | | | | | | | | | | | | The javadoc mistakenly claimed that GPS and PASSIVE location providers could be used with ACCESS_COARSE_LOCATION permissions. That was incorrect, and the javadoc has been amended. Bug: 7389249 Change-Id: I6f6489bb539679a962c67ae7263857700df33c82
* | LocationManager permissions cleanupVictoria Lease2012-10-181-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit is the result of a comprehensive permissions review for MR1 release. It addresses a number of deviations from spec and from MR0's behavior, bringing MR1 into sync with both. It also cleans up the concept of "location resolution permission", representing it internally as an enumerated access level to reduce reliance on cumbersome string manipulation. There's a function to convert the enum int into a permission string where needed, too. Additionally, this confines caller-identity-sensitive calls to the hopefully-obviously-named "getCallerAllowedResolutionLevel()". This should make it much easier to prove correctness with respect to accidentally calling functions that depend upon the caller's identity after identity has already been shed by Binder.clearCallingIdentity(). Change-Id: I446169aee8fb2fde26ac6d04b479b40253782acb
* | Prevent overflow in LocationRequest.setExpireIn()Laurent Tu2012-10-041-1/+9
| | | | | | | | | | | | | | | | Prevent overflow in LocationRequest.setExpireIn(), for example, when we pass in Long.MAX_VALUE. Bug: 7047435 Change-Id: Ie56928a59fb387173fbd3887c0ef9aede00f8152
* | Route GPS notifications to all users.Victoria Lease2012-10-011-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | This takes the easy way around notifying the correct users about GPS state transitions by notifying ALL the users(!). I've also laid groundwork for proper multiuser support in LocationManager and did a tiny bit of cleanup in GpsNetInitiatedHandler while I was looking at notifications. Bug: 7213552 Change-Id: I2d6dc65c459e55d110ac0f5f79ae7a87ad638ede
* | Fix for bug: #7173350. elapsedRealtimeNano() -> elapsedRealtimeNanos()Philip Milne2012-09-262-16/+16
| | | | | | | | Change-Id: Ie38952bbaace080e81e41e61350cda172951d548
* | Fix for bug: #7172778. Javadoc errors in LocationManager.Philip Milne2012-09-251-13/+17
| | | | | | | | Change-Id: Iaebd4cf00c8a33bcf4fc74eaa1dfec9675032826
* | Merge "Revert "Fix for bug: #7173350. elapsedRealtimeNano() -> ↵Philip Milne2012-09-241-2/+2
|\ \ | | | | | | | | | elapsedRealtimeNanos()"" into jb-mr1-dev
| * | Revert "Fix for bug: #7173350. elapsedRealtimeNano() -> elapsedRealtimeNanos()"Philip Milne2012-09-241-2/+2
| | | | | | | | | | | | | | | | | | This reverts commit 2f6d8829524dfca3a77e9a57c3b9c3862209877d Change-Id: Id5af767a09fc319127c4ebef837c5b7a7f75cb01
* | | Merge "Fix for bug: #7173350. elapsedRealtimeNano() -> ↵Philip Milne2012-09-241-2/+2
|\ \ \ | |/ / | | | | | | elapsedRealtimeNanos()" into jb-mr1-dev
| * | Fix for bug: #7173350. elapsedRealtimeNano() -> elapsedRealtimeNanos()Philip Milne2012-09-211-2/+2
| | | | | | | | | | | | Change-Id: I71c24ea10093ece07a0780e97bc641ff548c1a44
* | | Merge "Do not use passive GPS data for COARSE only apps." into jb-mr1-devVictoria Lease2012-09-232-1/+43
|\ \ \ | |/ / |/| |
| * | Do not use passive GPS data for COARSE only apps.Victoria Lease2012-09-212-1/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FusionEngine now attaches a secondary location that has never seen GPS data to its result. LocationFudger uses the GPS-less location so that COARSE apps never see data from the GPS provider. When the previous location is updated, the previous GPS-less location is carried over if the location update was GPS-only. Additionally, apps without FINE permission are not notified when GPS location changes, and any attempt to use GPS_PROVIDER without FINE permission is met by a stern SecurityException. Bug: 7153659 Change-Id: I12f26725782892038ce1133561e1908d91378a4a
* | | API REVIEW: Undeprecate Location.dump()Romain Guy2012-09-211-5/+1
|/ / | | | | | | | | | | Bug #7173109 Change-Id: Ia2f4a5b6255dae7ace4702f7d66ec30a077c9c79
* | Require ACCESS_FINE_LOCATION for Geofence use.Victoria Lease2012-09-131-5/+22
| | | | | | | | | | Bug: 7153226 Change-Id: I49236379e739fcda66bbc9a31cfdca9a87122aec