diff options
author | Svet Ganov <svetoslavganov@google.com> | 2014-10-23 12:39:08 -0700 |
---|---|---|
committer | Svetoslav Ganov <svetoslavganov@google.com> | 2014-10-23 19:43:54 +0000 |
commit | 45e50e99cdb10b43b062612c2e87e75841f2c424 (patch) | |
tree | dde571d5131ca46e4ae4ea217ae8eec1605e2ca0 /packages/PrintSpooler/src | |
parent | bec0c53a402224cf4807efd4077047c870f5b58f (diff) | |
download | frameworks_base-45e50e99cdb10b43b062612c2e87e75841f2c424.zip frameworks_base-45e50e99cdb10b43b062612c2e87e75841f2c424.tar.gz frameworks_base-45e50e99cdb10b43b062612c2e87e75841f2c424.tar.bz2 |
Set copies to one when saving to PDF.
One can save only one copy to PDF. Showing more that one copy when saving
to PDF enven in a disabled input box is confusing to the user. We now set
the copies to one when the PDF printer is selected.
bug:17631303
Change-Id: Ia04d144efc899e7f3836c19349d9c87f3ae8f0f0
Diffstat (limited to 'packages/PrintSpooler/src')
-rw-r--r-- | packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java b/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java index dc76218..d781cb0 100644 --- a/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java +++ b/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java @@ -1410,12 +1410,16 @@ public class PrintActivity extends Activity implements RemotePrintDocument.Updat mCopiesEditText.setEnabled(true); mCopiesEditText.setFocusableInTouchMode(true); } else { + CharSequence text = mCopiesEditText.getText(); + if (TextUtils.isEmpty(text) || !MIN_COPIES_STRING.equals(text.toString())) { + mCopiesEditText.setText(MIN_COPIES_STRING); + } mCopiesEditText.setEnabled(false); mCopiesEditText.setFocusable(false); } if (mCopiesEditText.getError() == null && TextUtils.isEmpty(mCopiesEditText.getText())) { - mCopiesEditText.setText(String.valueOf(MIN_COPIES)); + mCopiesEditText.setText(MIN_COPIES_STRING); mCopiesEditText.requestFocus(); } } |