diff options
author | Svetoslav Ganov <svetoslavganov@google.com> | 2013-09-26 19:21:06 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2013-09-26 19:21:06 +0000 |
commit | 3adc49c6780633b8bccc3b5b8dca10788c2288bc (patch) | |
tree | 1339ab0417a56d5c1e445fc20427c8cd3088ce93 | |
parent | c9cfd605a24cf20df5248d73804c584168db64c9 (diff) | |
parent | b0e68fdc9cb6ba292adc4590f406d921abea08d5 (diff) | |
download | frameworks_base-3adc49c6780633b8bccc3b5b8dca10788c2288bc.zip frameworks_base-3adc49c6780633b8bccc3b5b8dca10788c2288bc.tar.gz frameworks_base-3adc49c6780633b8bccc3b5b8dca10788c2288bc.tar.bz2 |
Merge "Disallow range selection if the document has unknown page count." into klp-dev
-rw-r--r-- | packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java b/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java index 48d7be0..d6cf76c 100644 --- a/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java +++ b/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java @@ -1092,7 +1092,9 @@ public class PrintJobConfigActivity extends Activity { } } - //TODO: Catch the error if start is less grater than the end. + // We intentionally do not catch the case of the from page being + // greater than the to page. When computing the requested pages + // we just swap them if necessary. mPageRangeEditText.setError(null); mPrintButton.setEnabled(true); @@ -1825,8 +1827,7 @@ public class PrintJobConfigActivity extends Activity { // Range options PrintDocumentInfo info = mDocument.info; - if (info != null && (info.getPageCount() > 0 - || info.getPageCount() == PrintDocumentInfo.PAGE_COUNT_UNKNOWN)) { + if (info != null && info.getPageCount() > 0) { if (info.getPageCount() == 1) { mRangeOptionsSpinner.setEnabled(false); } else { |