Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 98c8add7 authored by Isaac Katzenelson's avatar Isaac Katzenelson
Browse files

Populate user's selection from gmail invite

Bug:  6702756 When answering a calendar invite in Gmail, the Calendar app should open up with the answer pre-populated
Change-Id: Ic6cffa66b71e8750a314a085cb4443287b86bb0e
parent 094e99c9
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -20,7 +20,6 @@ import static android.provider.CalendarContract.EXTRA_EVENT_ALL_DAY;
import static android.provider.CalendarContract.EXTRA_EVENT_BEGIN_TIME;
import static android.provider.CalendarContract.EXTRA_EVENT_END_TIME;
import static android.provider.CalendarContract.Attendees.ATTENDEE_STATUS;
import static com.android.calendar.CalendarController.EVENT_ATTENDEE_RESPONSE;

import android.accounts.AccountManager;
import android.accounts.AccountManagerCallback;
@@ -1191,7 +1190,7 @@ public class AllInOneActivity extends Activity implements EventHandler,
                            Intent.FLAG_ACTIVITY_SINGLE_TOP);
                    intent.putExtra(EXTRA_EVENT_BEGIN_TIME, event.startTime.toMillis(false));
                    intent.putExtra(EXTRA_EVENT_END_TIME, event.endTime.toMillis(false));
                    intent.putExtra(EVENT_ATTENDEE_RESPONSE, response);
                    intent.putExtra(ATTENDEE_STATUS, response);
                    startActivity(intent);
                } else {
                    // start event info as a dialog
+0 −2
Original line number Diff line number Diff line
@@ -67,8 +67,6 @@ public class CalendarController {
    public static final int MIN_CALENDAR_WEEK = 0;
    public static final int MAX_CALENDAR_WEEK = 3497; // weeks between 1/1/1970 and 1/1/2037

    public static final String EVENT_ATTENDEE_RESPONSE = "attendeeResponse";

    private final Context mContext;

    // This uses a LinkedHashMap so that we can replace fragments based on the
+2 −2
Original line number Diff line number Diff line
@@ -17,7 +17,7 @@ package com.android.calendar;

import static android.provider.CalendarContract.EXTRA_EVENT_BEGIN_TIME;
import static android.provider.CalendarContract.EXTRA_EVENT_END_TIME;
import static com.android.calendar.CalendarController.EVENT_ATTENDEE_RESPONSE;
import static android.provider.CalendarContract.Attendees.ATTENDEE_STATUS;

import android.app.ActionBar;
import android.app.Activity;
@@ -58,7 +58,7 @@ public class EventInfoActivity extends Activity {
        } else if (intent != null && Intent.ACTION_VIEW.equals(intent.getAction())) {
            mStartMillis = intent.getLongExtra(EXTRA_EVENT_BEGIN_TIME, 0);
            mEndMillis = intent.getLongExtra(EXTRA_EVENT_END_TIME, 0);
            attendeeResponse = intent.getIntExtra(EVENT_ATTENDEE_RESPONSE,
            attendeeResponse = intent.getIntExtra(ATTENDEE_STATUS,
                    Attendees.ATTENDEE_STATUS_NONE);
            Uri data = intent.getData();
            if (data != null) {