aboutsummaryrefslogtreecommitdiffstats
path: root/cgeo-calendar
diff options
context:
space:
mode:
authorcampbeb <bpcampbell@gmail.com>2012-01-22 14:13:29 +0900
committercampbeb <bpcampbell@gmail.com>2012-01-22 14:13:29 +0900
commit7f288263991e16b58d60c42d40c0bf504aafcdfd (patch)
tree73e90d1b9699627d20b232ec73265019c36edcc3 /cgeo-calendar
parent04c458088210a672c5ac47e5fa508b9fba08d8ab (diff)
downloadcgeo-7f288263991e16b58d60c42d40c0bf504aafcdfd.zip
cgeo-7f288263991e16b58d60c42d40c0bf504aafcdfd.tar.gz
cgeo-7f288263991e16b58d60c42d40c0bf504aafcdfd.tar.bz2
Fix #1021
Make sure the add on exits when dialog is no longer displayed (either cancelled or calendar chosen).
Diffstat (limited to 'cgeo-calendar')
-rw-r--r--cgeo-calendar/src/cgeo/calendar/CalendarActivity.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java b/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java
index 530ecf0..191fc19 100644
--- a/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java
+++ b/cgeo-calendar/src/cgeo/calendar/CalendarActivity.java
@@ -123,6 +123,13 @@ public final class CalendarActivity extends Activity {
final Integer[] keys = calendars.keySet().toArray(new Integer[calendars.size()]);
final Integer calendarId = keys[item];
addToCalendar(calendarId);
+ finish();
+ }
+ });
+ builder.setOnCancelListener(new DialogInterface.OnCancelListener() {
+ @Override
+ public void onCancel(DialogInterface dialog) {
+ finish();
}
});
builder.create().show();