summaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorDave Langemak <dlangemak@google.com>2013-11-19 08:38:55 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2013-11-19 08:38:55 -0800
commit741c9c74ffead322c349242e3f72e8fd2957bd3d (patch)
treeecf434d52eacb121ccbb049e8d47f6bb45edd09b /packages
parent8ef1c53177fa43cf78eb8911af77bde87c9c1536 (diff)
parentd220d8202e67a82075ee20351657509ca0885b67 (diff)
downloadframeworks_base-741c9c74ffead322c349242e3f72e8fd2957bd3d.zip
frameworks_base-741c9c74ffead322c349242e3f72e8fd2957bd3d.tar.gz
frameworks_base-741c9c74ffead322c349242e3f72e8fd2957bd3d.tar.bz2
am d220d820: am c04aa87e: Merge "Fix incorrent page range parsing when custom print options used." into klp-dev
* commit 'd220d8202e67a82075ee20351657509ca0885b67': Fix incorrent page range parsing when custom print options used.
Diffstat (limited to 'packages')
-rw-r--r--packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java b/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java
index 88403a3..c1c7a4e 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/PrintJobConfigActivity.java
@@ -1529,9 +1529,13 @@ public class PrintJobConfigActivity extends Activity {
builder.append(',');
}
PageRange pageRange = pageRanges[i];
- builder.append(pageRange.getStart());
- builder.append('-');
- builder.append(pageRange.getEnd());
+ final int shownStartPage = pageRange.getStart() + 1;
+ final int shownEndPage = pageRange.getEnd() + 1;
+ builder.append(shownStartPage);
+ if (shownStartPage != shownEndPage) {
+ builder.append('-');
+ builder.append(shownEndPage);
+ }
}
mPageRangeEditText.setText(builder.toString());
}