Merge commit '05d24afb61e2fbd137468a065fd58685e1a62d78'
* commit '05d24afb61e2fbd137468a065fd58685e1a62d78':
AI 148368: Decrease CPU usage by throttling touch events
Merge commit '413cf5f4536b9c029d07f99b1c769c026313cd12'
* commit '413cf5f4536b9c029d07f99b1c769c026313cd12':
Track install/removal/update of packages that provide backup services
Merge commit 'b1d790b63e2115be558d451efbc914d1f8dfa846'
* commit 'b1d790b63e2115be558d451efbc914d1f8dfa846':
Pass null as savedState to indicate a full backup is required
Merge commit '9a6f25033c51390cbcc4eec38f27e0ac35e97f1c'
* commit '9a6f25033c51390cbcc4eec38f27e0ac35e97f1c':
Add a Backup Manager interface to request a full backup
Given a package name, the Backup Manager schedules a *full* (i.e. non-
incremental) backup pass for that package. Also added the state-file
handling for distinguishing to the target between the full and incremental
backup requests.
We are decreasing CPU usage at the cost of event latency. Events are queued up
and released to the app at the specified rate. You can
experiment with different values via:
adb shell setprop windowsmgr.max_events_per_sec 35
The new value is picked up when you let go and retouch the screen. No
reboot needed.
Also the following changes were made after profiling:
- In WindowManagerService, limit the call to userActivity() when we
have a flood touch events.
- In PowerManagerService, skip checking of permission if the caller
is system user.
- In PowerManagerService, integrated the functionality of gatherState()
into reactivateWakeLocksLocked(). They loop through the same data
structure and are called back to back.
BUG=1692771
Automated import of CL 148368
Merge commit 'f417247fa68524f2f34960f7389168eed7eb4a88'
* commit 'f417247fa68524f2f34960f7389168eed7eb4a88':
Further development of backup file handling
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.
Author: Christopher Tate <ctate@google.com>
Date: Mon May 4 16:38:11 2009 -0700
IBackupService now passes ParcelFileDescriptors rather than int fds
The outlines of backup state file / data file handling are now in place as well
in the BackupManagerService.
Author: Christopher Tate <ctate@google.com>
Date: Thu Apr 30 12:40:19 2009 -0700
Hide the backup stuff for now
Also adjust based on comments:
+ changed service intent string to conform to usage guidelines
+ only publish the IBackupService binder when invoked with the right
intent action
+ docs tweaks
Merge commit '1ab6e21237fc9f436be002d4f3821fce963a0a2a'
* commit '1ab6e21237fc9f436be002d4f3821fce963a0a2a':
Let screenOrientation="behind" works as expected
Merge commit '275555c8eb3fb5df6e7320873b88b77cdde85a9e'
* commit '275555c8eb3fb5df6e7320873b88b77cdde85a9e':
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>
Merge commit '15e3d0f082d551f8819fbe4b0d502cc108627876'
* commit '15e3d0f082d551f8819fbe4b0d502cc108627876':
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>
Merge commit '2cd006c8f927d3e364c32f946b844377bdc56d3e'
* commit '2cd006c8f927d3e364c32f946b844377bdc56d3e':
Make the home screen come up in the simulator.
Also tweak the dataChanged() api to have the client supply a package name. We
don't necessarily TRUST this, but we use it to narrow the set of packages requesting
a backup pass, no longer blithely scheduling a pass for all packages associated
with the caller's uid.
This change adds a sketched outline of the backup system architecture, with
all of the major pieces represented other than client-side helpers for
specific types of data. IBackupManager and BackupService are public so that
we can write test apps against SDK-domain symbols from the outset.
What code exists in this change hasn't been tested and may crash. It's the
beginnings of the real implementation but of course is barely begun.
Merge commit '79762a3ee34eb8be5549bcb183af844b6f19c266'
* commit '79762a3ee34eb8be5549bcb183af844b6f19c266':
location: Move DummyLocationProvider.java and LocationProviderImpl.java to the internal package.
Merge commit '7cb8ed23ab81b7cffdff6fc1cad473f55732ea66'
* commit '7cb8ed23ab81b7cffdff6fc1cad473f55732ea66':
location: Run LocationManagerService in a separate thread.
Now that we have GPS support in the emulator and public APIs for mock providers,
the fake provider support is no longer needed.
Signed-off-by: Mike Lockwood <lockwood@android.com>
Remove two second timeout for wakelock when broadcasting events to
location listeners. Instead, hold wakelock until receipt of the event
is acknowledged, either via a Binder call or the
PendingIntent.OnFinished interface.
Signed-off-by: Mike Lockwood <lockwood@android.com>
There are three major classes of changes here:
- Avoid writing lines where their values are often empty, false, or some other typical thing.
- Use partial writes to the PrintWriter to avoid creating temporary strings.
- Use StringBuilder where we need to generate real String objects (and where possible cache the result).
The wake lock was not being held until after we enabled location tracking,
so the check to see if the wake lock was held before propogating a
new location prevented us from receiving a network location as soon as we
enabled the provider.
This check is not necessary anyway, so this change removes it.
Signed-off-by: Mike Lockwood <lockwood@android.com>