diff options
author | Svetoslav <svetoslavganov@google.com> | 2013-08-12 22:36:50 -0700 |
---|---|---|
committer | Svetoslav Ganov <svetoslavganov@google.com> | 2013-08-14 00:06:53 -0700 |
commit | 66160bb881470a691005c8ad4e9c31c41fd5f810 (patch) | |
tree | f6d08dcb111ec41626cf8ce4c9ccda7c61ae57db /services | |
parent | 18d9c3cc6c7d69f7c5b36dafc4b66f0722b98a89 (diff) | |
download | frameworks_base-66160bb881470a691005c8ad4e9c31c41fd5f810.zip frameworks_base-66160bb881470a691005c8ad4e9c31c41fd5f810.tar.gz frameworks_base-66160bb881470a691005c8ad4e9c31c41fd5f810.tar.bz2 |
Partial implementation for the favorite and available printer tracking.
1. Added a dedicated class that keeps track of the user's favorite printers
based on past usage. We keep the last 50 uses and assign a decreasing weight
to older historical use records. The printer whose records' sum is the
largest is considered the favorite for the user and so on.
2. Factored out the printer discovery logic from the print job config activity
into a separate available printers provider class. It encapsulates all the
logic to communicated with the remote print services to discover printers,
keep track of added, updated, and removed printers.
3. Preliminary scetch of the printer chooser acitivty that will show all the
printers.
Change-Id: I5524665f2a9a565f186db85214d5e41a44f4812e
Diffstat (limited to 'services')
-rw-r--r-- | services/java/com/android/server/print/RemotePrintService.java | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/services/java/com/android/server/print/RemotePrintService.java b/services/java/com/android/server/print/RemotePrintService.java index 322de6c..491dddc 100644 --- a/services/java/com/android/server/print/RemotePrintService.java +++ b/services/java/com/android/server/print/RemotePrintService.java @@ -110,6 +110,7 @@ final class RemotePrintService implements DeathRecipient { } private void handleBinderDied() { + mPendingCommands.clear(); ensureUnbound(); } |