15cbc8a03250eafdf947cd8ad4e77f34444d5ba4 |
|
11-Jul-2014 |
Svetoslav <svetoslavganov@google.com> |
Addressing comments for the print preview feature. Change-Id: Ib72140a912e22f859258d970e0d1c4ef06e807d5
/frameworks/base/core/java/android/print/PageRange.java
|
525a66b2bb5abf844aff2109bdc9ed819566bece |
|
15-Jun-2014 |
Svet Ganov <svetoslavganov@google.com> |
Adding print preview. This change adds the pring preview part of the new print UX. The UI has two parts, the top section is the print options and the bottom section print preview with a list of pages. The user can interact only with one of them. When print options are expanded they cover the preview content and a scrim is laid out on top of the preview. Tapping the scrim collapses the print options. When the user types in page ranges and closes the options to look at the preview, the latter is updated to show only these pages. In the list of pages the user can further prune pages by deselecting them. Change-Id: I0b23d2c598afe2a34400ccfa43e4e935af83c72f
/frameworks/base/core/java/android/print/PageRange.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/PageRange.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/PageRange.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/PageRange.java
|
88d199130d44c6bacb383a7757e782cf97483c68 |
|
22-Jul-2013 |
Svetoslav Ganov <svetoslavganov@google.com> |
Implement persistence/restoring of print spooler state. 1. Implemented the persistence and restoring of the print spooler state. The print spooler state is saved as an XML on every print job change and is restored when we bind to the spooler. The system does not unbind from the spooler until the state persistence completes. We are now storing the entire state, i.e. all print jobs, when a single one changes. This is not optimal but we are not expecting to have many such at the same time, so for now we err for simplicity of implementation. 2. Enforcing a non-empty print job name. 3. Hidden the STATE_CREATED print job state which should never be visible to a client since this is the state of a print job during construction, i.e. the print dialog is up and we are doing back and forth with the app. 4. Fixed some PrintAttributes APIs that were incorrectly taking in a PackageManager instance. 5. Updated the PrintSpooler build file due to splitting the framework into multiple jars. Change-Id: I52c88eaa1ec9c64920359cc143c79832a4c3d25b
/frameworks/base/core/java/android/print/PageRange.java
|
fd90651cfcc7e2b75254666fd6861038b72fb4ac |
|
24-Jun-2013 |
Svetoslav <svetoslavganov@google.com> |
Print APIs documentation update Change-Id: I0df438e45ef540cc42c9ee5baafc816ebafa1c7b
/frameworks/base/core/java/android/print/PageRange.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/PageRange.java
|