145 Commits

Author SHA1 Message Date
Mike Lockwood
0528b9b26a location: Location Manager wakelock cleanup
Location Providers are now responsible for their own wakelocks and scheduling.

Also fixed a deadlock in LocationManagerService in the code for releasing
wakelocks after client notifications have been received.
The fix is to use the Receiver object and mWakeLock for synchronization
 instead of the global mLock lock.

Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-05-07 11:02:22 -04:00
Dianne Hackborn
7a13559501 merged 231cc608d06ffc31c24bf8aa8c8275bdd2636581 2009-05-06 00:28:37 -07:00
Dianne Hackborn
231cc608d0 Rewrite SyncStorageEngine to use flat files and in-memory data structures.
The previous implementation used a database for storing all of its state, which could cause
a significant amount of IO activity as its tables were updated through the stages of a sync.
This new implementation replaces that in-memory data structures, with hand-written code
for writing them to persistent storage.

There are now 4 files associated with this class, holding various pieces of its state that
should be consistent.  These are everything from a main XML file of account information that
must always be retained, to a binary file of per-day statistics that can be thrown away at
any time.  Writes of these files as scheduled at various times based on their importance of
the frequency at which they change.

Because the database no longer exists, there needs to be a new explicit interface for
interacting with the sync manager database.  This is provided by new APIs on IContentService,
with a hidden method on ContentResolver to retrieve the IContentService so that various
system entities can use it.  Other changes in other projects are required to update to the
new API.

The goal here is to have as little an impact on the code and functionality outside of
SyncStorageEngine, though due to the necessary change in API it is still somewhat extensive.
2009-05-05 15:40:53 -07:00
Mike Lockwood
e90c0da675 am 275555c: location: Add support for location providers outside of the
Merge commit '275555c8eb3fb5df6e7320873b88b77cdde85a9e'

* commit '275555c8eb3fb5df6e7320873b88b77cdde85a9e':
  location: Add support for location providers outside of the system process.
2009-05-01 12:39:03 -07:00
Mike Lockwood
275555c8eb location: Add support for location providers outside of the system process.
Also added new permissions android.permission.INSTALL_LOCATION_PROVIDER
and android.permission.INSTALL_LOCATION_COLLECTOR to the public API.

Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-05-01 15:06:31 -04:00
Mike Lockwood
ac7a3de471 am 15e3d0f: location: Use ILocationProvider Binder interface for all loc
Merge commit '15e3d0f082d551f8819fbe4b0d502cc108627876'

* commit '15e3d0f082d551f8819fbe4b0d502cc108627876':
  location: Use ILocationProvider Binder interface for all location providers.
2009-05-01 05:26:44 -07:00
Mike Lockwood
15e3d0f082 location: Use ILocationProvider Binder interface for all location providers.
This change eliminates the LocationProviderImpl class which had been used
for location providers running in the system process.
Now the LocationProvider base class is only used to implement the
LocationManager.createProvider() method for retrieving provider information.
Added a new IGpsStatusProvider interface for providers that serve GPS status.

Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-05-01 08:24:47 -04:00
Fred Quintana
718d8a2d7f decouple SyncAdapter from ContentProvider 2009-04-30 17:28:09 -07:00
Jorg Pleumann
e07cd1a4c3 am 19aa8e0: am b867019: AI 147725: Some fixes for the CTS test runner. O
Merge commit '19aa8e01b8fe4ebd6d518bd48ea9b53ec95a49a7'

* commit '19aa8e01b8fe4ebd6d518bd48ea9b53ec95a49a7':
  AI 147725: Some fixes for the CTS test runner. One is a
2009-04-29 13:35:41 -07:00
Mitsuru Oshima
c2839e0870 am 13735a2: Merge branch \'readonly-p4-donut\' into donut
Merge commit '13735a255dedd2c2e3b0cff66f0be2e17671f553'

* commit '13735a255dedd2c2e3b0cff66f0be2e17671f553':
  AI 147976: Compatibility mode support. Part 2.
2009-04-29 13:35:38 -07:00
Mike Lockwood
05d0243296 am 79762a3: location: Move DummyLocationProvider.java and LocationProvid
Merge commit '79762a3ee34eb8be5549bcb183af844b6f19c266'

* commit '79762a3ee34eb8be5549bcb183af844b6f19c266':
  location: Move DummyLocationProvider.java and LocationProviderImpl.java to the internal package.
2009-04-29 13:35:34 -07:00
Jorg Pleumann
19aa8e01b8 am b867019: AI 147725: Some fixes for the CTS test runner. One is a
Merge commit 'b867019173d20cd4fd7ee79a3ce924096e95a241' into donut

* commit 'b867019173d20cd4fd7ee79a3ce924096e95a241':
  AI 147725: Some fixes for the CTS test runner. One is a
2009-04-28 21:54:10 -07:00
Mitsuru Oshima
13735a255d Merge branch 'readonly-p4-donut' into donut 2009-04-28 18:13:25 -07:00
Mitsuru Oshima
8169daed2f AI 147976: Compatibility mode support. Part 2.
* Introduced ApplicationScale (may not be good name. CompatibilityScale? CanvasScale? Pls let me know if you have better idea)
  * Changes to RootView / SurfaceView
  - Makes the app believe it's running in the supported density/resolution.
  - Makes the window manager believe it's running at the right density/resolution.
  * Added methods to Rect/Event for scaling up/down.
  Known issues:
  * certain kind of images (such as nine patch for buttons) seesm to be loaded not by app, thus does not take the scale into account,
  which, in turn, is causing layout issue.
  * ZoomButton in MapView is rendered in wrong place
  * Transparent region on Surface is not correct
  * Specifying different densities in one process is not working.
  BUG=1770627

Automated import of CL 147976
2009-04-28 18:12:09 -07:00
Mike Lockwood
79762a3ee3 location: Move DummyLocationProvider.java and LocationProviderImpl.java to the internal package.
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-04-28 12:42:08 -04:00
Fred Quintana
0eabf0228a change the IsolatedContext to have a test version of the AccountManager that has no IBinder to the AccountManagerService. 2009-04-27 15:08:17 -07:00
Jorg Pleumann
b867019173 AI 147725: Some fixes for the CTS test runner. One is a
workaround for the binder problems which occur
  when too many tests are executed in too little
  time. The other is a fix for the memory cleanup
  that was added a while ago, but should have
  affected non-static fields, not static ones.
  BUG=1796494

Automated import of CL 147725
2009-04-24 13:08:47 -07:00
Fred Quintana
d9d2f1140b change the sync framework and users to understand Account 2009-04-23 15:37:45 -07:00
Andy Stadler
72d5de71f2 AI 147169: am: CL 147167 am: CL 147162 Emphasize in the javadoc that the "pkg" parameters to
InstrumentationTestCase and its descendants should be the
  package manager package name (not the java package name, and
  not the test package) of the package holding the Activity
  under test.
  Added similar notations to the ApiDemos call sites.
  JAVADOC ONLY - should be safe change for cupcake sdk.
  Original author: stadler
  Merged from: //branches/cupcake/...
  Original author: android-build

Automated import of CL 147169
2009-04-21 11:54:14 -07:00
Andy Stadler
df2a463b01 AI 147167: am: CL 147162 Emphasize in the javadoc that the "pkg" parameters to
InstrumentationTestCase and its descendants should be the
  package manager package name (not the java package name, and
  not the test package) of the package holding the Activity
  under test.
  Added similar notations to the ApiDemos call sites.
  JAVADOC ONLY - should be safe change for cupcake sdk.
  Original author: stadler
  Merged from: //branches/cupcake/...

Automated import of CL 147167
2009-04-21 11:51:43 -07:00
Andy Stadler
54bd245f57 AI 147162: Emphasize in the javadoc that the "pkg" parameters to
InstrumentationTestCase and its descendants should be the
  package manager package name (not the java package name, and
  not the test package) of the package holding the Activity
  under test.
  Added similar notations to the ApiDemos call sites.
  JAVADOC ONLY - should be safe change for cupcake sdk.
  BUG=1783981

Automated import of CL 147162
2009-04-21 11:48:54 -07:00
Urs Grob
7d41b8c26a AI 146828: am: CL 146743 am: CL 146711 Enhancing the test runner. Now it filters BrokenTests and only executes tests
annotated with SideEffect if the host is running in single test mode.
  Also adding some cleanup mechanism and some logcat logging about memory consumption
  Original author: ursg
  Merged from: //branches/cupcake/...
  Original author: android-build

Automated import of CL 146828
2009-04-18 22:47:14 -07:00
Urs Grob
da13ef5dca AI 146743: am: CL 146711 Enhancing the test runner. Now it filters BrokenTests and only executes tests
annotated with SideEffect if the host is running in single test mode.
  Also adding some cleanup mechanism and some logcat logging about memory consumption
  Original author: ursg
  Merged from: //branches/cupcake/...

Automated import of CL 146743
2009-04-17 11:30:14 -07:00
Urs Grob
358d23017d AI 146711: Enhancing the test runner. Now it filters BrokenTests and only executes tests
annotated with SideEffect if the host is running in single test mode.
  Also adding some cleanup mechanism and some logcat logging about memory consumption
  BUG=1789657

Automated import of CL 146711
2009-04-17 02:09:00 -07:00
Dianne Hackborn
935ae463d4 AI 145994: Integrate #145778 from Donut.
Automated import of CL 145994
2009-04-13 16:11:55 -07:00
Andy Stadler
f8a7ceaef2 AI 145778: Manual merge changes 145382-145384 from cupcake.
Automated import of CL 145778
2009-04-10 16:24:47 -07:00
Dianne Hackborn
48276ab989 AI 145383: API review: clean up a bunch of @hides that have been pending API review.
Either expose them, or official hide them with an explanation for why.
  BUG=1779439

Automated import of CL 145383
2009-04-09 12:32:19 -07:00
Mike Lockwood
f6f9792d44 AI 144453: am: CL 144452 More Location Manager cleanup:
Remove 1 Hz "heartbeat" polling of location providers from LocationManagerService.
  Now location providers report their location to LocationManagerService via
  LocationManager.setLocation() rather than waiting to be polled.
  This reduces GPS fix latency by up to one second.
  Remove LocationProvderImpl.getLocation().
  Since we are no longer polling, this method is no longer necessary.
  BUG=1729031
  Original author: lockwood

Automated import of CL 144453
2009-04-03 08:24:47 -07:00
Mike Lockwood
4e50b78bda AI 144452: More Location Manager cleanup:
Remove 1 Hz "heartbeat" polling of location providers from LocationManagerService.
  Now location providers report their location to LocationManagerService via
  LocationManager.setLocation() rather than waiting to be polled.
  This reduces GPS fix latency by up to one second.
  Remove LocationProvderImpl.getLocation().
  Since we are no longer polling, this method is no longer necessary.
  BUG=1729031

Automated import of CL 144452
2009-04-03 08:24:43 -07:00
Brett Chabot
ff51fe211d AI 144107: am: CL 144098 am: CL 144093 Fix NPE in ActivityUnitTestCase.
Original author: brettchabot
  Merged from: //branches/cupcake/...
  Original author: android-build
  Merged from: //branches/donutburger/...

Automated import of CL 144107
2009-04-02 09:56:38 -07:00
Brett Chabot
79ad626231 AI 144098: am: CL 144093 Fix NPE in ActivityUnitTestCase.
Original author: brettchabot
  Merged from: //branches/cupcake/...

Automated import of CL 144098
2009-04-01 15:15:33 -07:00
Brett Chabot
9a89f145d3 AI 144093: Fix NPE in ActivityUnitTestCase.
BUG=1751731

Automated import of CL 144093
2009-04-01 15:12:07 -07:00
Brett Chabot
2c62f84add AI 143872: am: CL 143870 am: CL 143869 Change InstrumentationTestRunner so all tests in the application are run when no other arguments are supplied, instead of running only tests in the app's package.
Original author: brettchabot
  Merged from: //branches/cupcake/...
  Original author: android-build
  Merged from: //branches/donutburger/...

Automated import of CL 143872
2009-03-31 17:07:19 -07:00
Brett Chabot
61b10ac95d AI 143870: am: CL 143869 Change InstrumentationTestRunner so all tests in the application are run when no other arguments are supplied, instead of running only tests in the app's package.
Original author: brettchabot
  Merged from: //branches/cupcake/...

Automated import of CL 143870
2009-03-31 17:04:34 -07:00
Brett Chabot
a1d701ef2f AI 143869: Change InstrumentationTestRunner so all tests in the application are run when no other arguments are supplied, instead of running only tests in the app's package.
BUG=1749513

Automated import of CL 143869
2009-03-31 17:03:46 -07:00
The Android Open Source Project
9066cfe988 auto import from //depot/cupcake/@135843 2009-03-03 19:31:44 -08:00
The Android Open Source Project
d83a98f4ce auto import from //depot/cupcake/@135843 2009-03-03 18:28:45 -08:00
The Android Open Source Project
076357b856 auto import from //depot/cupcake/@132589 2009-03-03 14:04:24 -08:00
The Android Open Source Project
3dec7d563a auto import from //depot/cupcake/@137055 2009-03-02 22:54:33 -08:00
The Android Open Source Project
3001a03543 auto import from //branches/cupcake/...@132276 2009-02-19 10:57:31 -08:00
The Android Open Source Project
d24b8183b9 auto import from //branches/cupcake/...@130745 2009-02-10 15:44:00 -08:00
The Android Open Source Project
f1e484acb5 auto import from //branches/cupcake/...@127436 2009-01-22 00:13:42 -08:00
The Android Open Source Project
b798689749 auto import from //branches/cupcake/...@125939 2009-01-09 17:51:23 -08:00
The Android Open Source Project
f013e1afd1 Code drop from //branches/cupcake/...@124589 2008-12-17 18:05:43 -08:00
The Android Open Source Project
54b6cfa9a9 Initial Contribution 2008-10-21 07:00:00 -07:00