d74d1e549168ba521e8009961b76e8718be37aa1 |
|
18-Mar-2016 |
Philip P. Moltmann <moltmann@google.com> |
Change hasCustomPrintIcon and setStatus as requested by API council. Bonus: null advanced keys produced a exception deep in the print spooler. Hence prevent null keys on the surface from now on. Bug: 27716355 Change-Id: I3c064956f4e670cd7091437ade06605aa8d797b0
/frameworks/base/core/java/android/print/PrinterInfo.java
|
c2ad22663ba8cbd0ceb35e760c5f3c4084fb5033 |
|
13-Jan-2016 |
Philip P. Moltmann <moltmann@google.com> |
Clean up API for PrinterInfo. - Make immutable - Check parameters - Check state while unparcelling Change-Id: I13959845ca508936331488506380e894f49abf25
/frameworks/base/core/java/android/print/PrinterInfo.java
|
b8c1a02adb1e55bae04bde3f5046fe324abed9e9 |
|
06-Jan-2016 |
Philip P. Moltmann <moltmann@google.com> |
Fix wrong annotation for PrintInfo.Builder.setStatus Change-Id: I11fd68497c6229d16c0827f4753f485e9095649d
/frameworks/base/core/java/android/print/PrinterInfo.java
|
bb36206f08797156caed236671d36b5a34682f95 |
|
23-Dec-2015 |
Philip P. Moltmann <moltmann@google.com> |
Rename variable that hides the contatining classes name. Change-Id: Iad0a9b341a866d33d10b7a389d243e677a65057c
/frameworks/base/core/java/android/print/PrinterInfo.java
|
c43639c3067dda5df189fb3cbf14f256c17e677d |
|
18-Dec-2015 |
Philip P. Moltmann <moltmann@google.com> |
Clean up print subsystem - Stop using deprecated APIs - Fix all public and some internal javadoc - Add @Decorations to public APIs - Some minor cleanup, e.g. don't use variables with overlapping names in same scope - remove unnecessary properties from manifest (they are set by the build system) Change-Id: I0ce8849a516414763fe9de76c3a18ce17d896816
/frameworks/base/core/java/android/print/PrinterInfo.java
|
bb9f686b40743df2642b7d3b7778dbf7284ae665 |
|
01-Dec-2015 |
Philip P. Moltmann <moltmann@google.com> |
Allow a print service to specify per printer icons, description and info-activities The icon is loaded from the discovery session only when it is displayed to avoid having to store too many icons in memory. Also the icons are not maintained in the historical printers. Only if the printers are available nice icons are shown. A historical printer is updated with the appropriate properties (including icon) once it becomes available. Bug: 24135005 Change-Id: Iec389bab514b024634be8fb5fc8928371cba8740
/frameworks/base/core/java/android/print/PrinterInfo.java
|
4d4c66dd38e940082e385b49a33f4022ab04c738 |
|
25-Oct-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Update the documentaton of the android.print package. bug:10551786 bug:10551697 bug:10705082 bug:10741641 bug:11318976 bug:10550979 bug:10551761 Change-Id: I46ceb66a69b6d32d6b417356178f67f2e25e891a
/frameworks/base/core/java/android/print/PrinterInfo.java
|
704697b6197262678e930daa831a1916ddee4dcf |
|
22-Sep-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Adding hidden APIs for observing the print jobs state. This is needed for implementing the print job settigns UI. bug:10935736 Change-Id: I63b42cbf4ce6a259fa1af47fa368b148ca5621c1
/frameworks/base/core/java/android/print/PrinterInfo.java
|
651dd4e6ee6510caf9f15c51094a11121af17ec2 |
|
12-Sep-2013 |
Svetoslav <svetoslavganov@google.com> |
Remove unneeded print APIs and update the min margins APIs. 1. Removed unneeded code in Resolution that was storing its label as resource and package name. We do not have predefined resolutions, therefore we always persist the label. 2. Renamed the print attribute margins to minMargins to reflect that these are the minimal margins the printer support. Updated the docs as well. 3. Renamed the create method of all builder to build. bug:10727487 Change-Id: Ie72ab8aaa5215b8bd2853885011b3b4efa4deb2e
/frameworks/base/core/java/android/print/PrinterInfo.java
|
aec1417ca9eb63209668ac17da90cf8a07c6076c |
|
27-Aug-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Print APIs update. 1. Added scale to fit and scale to fill fitting modes. 2. Added APIs for a print app to specify which constraints imposed by the print attributes were satsified during a layout so they are not handled by the printer again, e.g. if the content is to be in landscape the the app generated such content the printer should rotate the content again. 3. Added some printer statuses. 4. Added a helper class that generates PDF documents with correct size based on the passed in print attributes. 5. Exposed a ctor for PageRange which was hidden by mistake and apps could not create page ranges. Added API for changing the printer status. Change-Id: If1334a61d2d931027b98075f653018d456b1b768
/frameworks/base/core/java/android/print/PrinterInfo.java
|
269403b032f965ff3847eb982c2f697229dc5a92 |
|
15-Aug-2013 |
Svetoslav <svetoslavganov@google.com> |
Implemented advanced printer selection and API refactoring. 1. Added past printer history tracking and merging favorite printers with discovered printers. 2. Added save as PDF support. 3. Added all printers activity with search capability and optional add printers chooser (if any print service provides add printers activity) 4. Refactored the printer discovery session APIs. Now one session can have multiple window discovery windows and the session stores the printers found during past discovery periods. 5. Merged the print spooler and the print spooler service - much simpler and easier to maintain. Change-Id: I4830b0eb6367e1c748b768a5ea9ea11baf36cfad
/frameworks/base/core/java/android/print/PrinterInfo.java
|
798bed6cc7d273e72b0253288605db9cd2b57740 |
|
11-Aug-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Refinement of the print service APIs. 1. Factored out the printer discovery APIs of a print service in a dedicated session object that is created by the print service on demand. This ensures that added/removed/updated printers from one session do not interfere with another session. 2. Updated the app facing APIs to pass in a document info along with a printed file. Also exposed the print file adapter so apps that create a temporary file for printing can intercept when it is read by the system so the file can be deleted. 3. Updated the print service documentation. Change-Id: I3473d586c26d8bda1cf7e2bdacb441aa9df982ed
/frameworks/base/core/java/android/print/PrinterInfo.java
|
8c43376ea83a67414bd6823a472b76d41160239e |
|
02-Aug-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
First cut of the print notifications. 1. Added notifications for a queued print job, for a started print job, for ongoing canceling a print job, and for a failed print job. The notifications for queued and started state have a cancel action. The notification for failed print job has a cancel and a restart action. 2. Propagating failure message from the print service to the notifications. 3. PrintJobConfigActivity was not setting the initial value for the print job copies and was not updating the UI immediately after creation. 4. Refactored PrintJobConfigActivity to avoid using the hack to avoid reaction for item selection change in a spinner for an event that happened before the callback was registered. 5. Removed the label attribute from PrinterInfo and now PrinterId is composed of the printer name and the service component name. This is nice since for restarting print jobs we do not need to store information about the printer except the printer id which is already part of the PrintJobInfo's data. Also the printer name is not expected to change anyway. 6. Allowing cancellation of a queued print job. Also no print job is cancelled without asking the managing print service to do that. Before we were immediately canceling print jobs in queued state but it was possible for a buggy print service to not set the print job state to started before starting to do expensive work that will not be canceled. 7. PrintServiceInfo was throwing an exception the the meta-data XML for the print service was not well-formed which would crash the system process. Now we just ignore not well-formed meta-data. 8. Removed unused permissions from the PrintSpooler's manifest. Change-Id: Iba2dd14b487f56e137b90d1da17c3033422ab5e6
/frameworks/base/core/java/android/print/PrinterInfo.java
|
55b409a97cf6376399a0940313ea852368727d6f |
|
01-Aug-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Iteration of the print sub-system. 1. Added APIs for adding partially initialized PrintInfo objects enabling light-weight lookps for print serivces that want to populate the list of available printers without querying each of them for its capabilities. This includes APIs for the system to request from a print service to update certain printers. 2. Fixed a bug in PrinterId#equals(). 3. Added equals and hasCode implementaion to PrinterInfo. Also the defaul in PrinterInfo are now an array instead of a SparseArray - cheaper. 4. Now PrintJobConfigActivity works with partially specified printers. Specifically, if such a printer is selected the activity is requesting from the print service to update the printer. We are currently not handling the timeout case. It also handles udpated pritners. Change-Id: I5e83e924ef597c9e22cbd06a971d4f4d3bd3a9c1
/frameworks/base/core/java/android/print/PrinterInfo.java
|
85b1f883056a1d74473fd9ce774948878f389ab6 |
|
25-Jul-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Iteration on the print sub-system. 1. API changes: Moved copies API from PrintAttributes to PrintJobInfo; Changed the PageRange list to an array in PrintDocumentAdapter#onWrite; Added onCancelled method to the layout and write callbacks. 2. Refactored the serialization of remote layout and write commands. Now the commands are serialized by the code in the client instead in the spooler. The benefit is simple code since the client has to do a serialization to delegate to the main thread anyway. The increased IPC found is fine since these calls are quite unfrequent. 3. Removed an unused file: IPrintSpoolerObserver.aidl 4. Added equals and hasCode implementation to PageRange, PrintAttributes, MediaSize, Resolution, Margins, Tray, PrintDocumentInfo. 5. Added shortcut path for query APIs on PrintJob that return cached values if the print job is in a uncuttable state, i.e. completed or cancelled. Failed print jobs can be restarted. 6. PrintJobInfo was not properly serialized. 7. Updated the look of the print dialog to be stable if there is and there isn't currently selected printer. 8. PrintJobCOnfigActivity now calls onLayout on every print attributes change but requests a write only on print preview or print button press. Also if the layout did not change the content and it is already written no subsequent call is made. Also if the selected pages change and we already have them no subsequent call to write is made. Also the app is called with print preview attribute set when performing layout and with it cleared after the print button is pressed. A lot of changes making sure that only valid actions are enabled in the activity (looks like a dialog) at a given time frame. The print job config activity is also hidden after we got all the data, i.e. layout and write are done. 9. The callback from the print spooler to the system are scheduled via messages to avoid lock being held during the call. It was hard to guarantee that since a method holding a lock may be calling one that would like to release the lock at some point to make the callbacks. 10. Print spooler state is persisted only if something changes in a completed print job, i.e. not one that is being constructed due the print job config dialog. 11. Fixed a potential race in the RemotePrintSpooler where it was possible that a client that got a handle to the remote spooler calls into an unbound spooler. E.g: the client gets the remote interface with a lock held, now the client releases the lock to avoid IPC with a lock, during the IPC scheduling the spooler has notified the system that it is done and the system unbinds from it, now the client's IPC is made to a spooler that is disconnected. Change-Id: Ie9c42255940a27ecaed21a4d326a663a4788ac9d
/frameworks/base/core/java/android/print/PrinterInfo.java
|
a00271533f639c8ed36429c663889ac9f654bc72 |
|
25-Jun-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Refactoring of the print sub-system and API clean up. 1. Now a user state has ins own spooler since the spooler app is running per user. The user state registers an observer for the state of the spooler to get information needed to orchestrate unbinding from print serivces that have no work and eventually unbinding from the spooler when all no service has any work. 2. Abstracted a remote print service from the perspective of the system in a class that is transparently managing binding and unbinding to the remote instance. 3. Abstracted the remote print spooler to transparently manage binding and unbinding to the remote instance when there is work and when there is no work, respectively. 4. Cleaned up the print document adapter (ex-PrintAdapter) APIs to enable implementing the all callbacks on a thread of choice. If the document is really small, using the main thread makes sense. Now if an app that does not need the UI state to layout the printed content, it can schedule all the work for allocating resources, laying out, writing, and releasing resources on a dedicated thread. 5. Added info class for the printed document that is now propagated the the print services. A print service gets an instance of a new document class that encapsulates the document info and a method to access the document's data. 6. Added APIs for describing the type of a document to the new document info class. This allows a print service to do smarts based on the doc type. For now we have only photo and document types. 7. Renamed the systemReady method for system services that implement it with different semantics to systemRunning. Such methods assume the the service can run third-party code which is not the same as systemReady. 8. Cleaned up the print job configuration activity. 9. Sigh... code clean up here and there. Factoring out classes to improve readability. Change-Id: I637ba28412793166cbf519273fdf022241159a92
/frameworks/base/core/java/android/print/PrinterInfo.java
|
4b9a4d16872bbb50712e007b419ac0b35ff1582d |
|
12-Jun-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Print - platform APIs Related changes: Skia (inlcude PDF APIs): https://googleplex-android-review.googlesource.com/#/c/305814/ Canvas to PDF: https://googleplex-android-review.googlesource.com/#/c/319367/ Settings (initial version): https://googleplex-android-review.googlesource.com/#/c/306077/ Build: https://googleplex-android-review.googlesource.com/#/c/292437/ Sample print services: https://googleplex-android-review.googlesource.com/#/c/281785/ Change-Id: I104d12efd12577f05c7b9b2a5e5e49125c0f09da
/frameworks/base/core/java/android/print/PrinterInfo.java
|