aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcampbeb <bpcampbell@gmail.com>2012-01-22 12:34:02 +0900
committercampbeb <bpcampbell@gmail.com>2012-01-22 12:34:02 +0900
commit1d3e7a77fd0eb7801f930564f8293698b1837bae (patch)
tree8d49eade7150fc17997106851cc0e802d6da78cb
parent04c458088210a672c5ac47e5fa508b9fba08d8ab (diff)
downloadcgeo-1d3e7a77fd0eb7801f930564f8293698b1837bae.zip
cgeo-1d3e7a77fd0eb7801f930564f8293698b1837bae.tar.gz
cgeo-1d3e7a77fd0eb7801f930564f8293698b1837bae.tar.bz2
Fix #1019 by correcting the index for substring calls.
-rw-r--r--cgeo-calendar/src/cgeo/calendar/CalendarActivity.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java b/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java
index 530ecf0..4e889e0 100644
--- a/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java
+++ b/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java
@@ -153,7 +153,7 @@ public final class CalendarActivity extends Activity {
String text = spanned.toString();
final ImageSpan[] spans = spanned.getSpans(0, spanned.length(), ImageSpan.class);
for (int i = spans.length - 1; i >= 0; i--) {
- text = text.substring(0, spanned.getSpanStart(spans[i]) - 1) + text.substring(spanned.getSpanEnd(spans[i]) + 1);
+ text = text.substring(0, spanned.getSpanStart(spans[i])) + text.substring(spanned.getSpanEnd(spans[i]));
}
if (text.length() > 0) {
description.append("\n\n");