OSDN Git Service

Print attributes hint not honored.
authorSvetoslav Ganov <svetoslavganov@google.com>
Mon, 30 Sep 2013 16:04:50 +0000 (09:04 -0700)
committerSvetoslav <svetoslavganov@google.com>
Fri, 4 Oct 2013 18:45:15 +0000 (11:45 -0700)
commit7be27acac922b5ea66ec6b464ded6f057bd6f1e5
treecfc3d44f5fbe42a88de0f540c8c2a0b07a94b37f
parent5c126892ec53772d784fcf9cef9165acf1d92ce3
Print attributes hint not honored.

1. Initially we have a single printer, the fake PDF printer, and
   wait for printers to be discovered. This printer was handling
   only a couple of media sizes. Hence, if the app provides a
   media size hint and the PDF printer does not support it, we
   were essentially ignoring the suggested media size since it
   was not supported by the selected printer and we fell back to
   the default paper size for that printer. The fake PDF printer
   should support all predefined media sizes.

2. The list of available paper sizes was shown in the order they
   are added ignoring the current locale. It is much better user
   experience if the media sizes used in the current locale are
   shown at the top and all others after that. Also the media
   sizes for the current locale should be alphabetically ordered
   so the user can quickly find the desired one.

3. The orientation was reset on media size or printer change.

bug:10564537

Change-Id: Iaa0d42242730ce69cea3effd4d0f4bc087068804
18 files changed:
api/current.txt
core/java/android/print/PrintAttributes.java
packages/PrintSpooler/res/values-be/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-be/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-en-rCA/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-en-rCA/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-en-rUS/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-en-rUS/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-es-rUS/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-es-rUS/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-ja/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-ja/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-zh-rCN/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values-zh-rCN/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/res/values/arrays.xml [new file with mode: 0644]
packages/PrintSpooler/res/values/donottranslate.xml [new file with mode: 0644]
packages/PrintSpooler/src/com/android/printspooler/MediaSizeUtils.java [new file with mode: 0644]
packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java