|
32 | 32 | import android.content.res.Configuration; |
33 | 33 | import android.content.res.Resources; |
34 | 34 | import android.content.res.TypedArray; |
35 | | -import android.content.res.Resources.Theme; |
36 | 35 | import android.database.Cursor; |
37 | 36 | import android.graphics.Bitmap; |
38 | 37 | import android.graphics.Canvas; |
|
55 | 54 | import android.util.EventLog; |
56 | 55 | import android.util.Log; |
57 | 56 | import android.util.SparseArray; |
58 | | -import android.util.TypedValue; |
59 | 57 | import android.view.ActionMode; |
60 | 58 | import android.view.ContextMenu; |
61 | 59 | import android.view.ContextMenu.ContextMenuInfo; |
@@ -3208,7 +3206,8 @@ public void startActivityForResult(Intent intent, int requestCode) { |
3208 | 3206 | * @param requestCode If >= 0, this code will be returned in |
3209 | 3207 | * onActivityResult() when the activity exits. |
3210 | 3208 | * @param options Additional options for how the Activity should be started. |
3211 | | - * May be null if there are no options. |
| 3209 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3210 | + * Context.startActivity(Intent, Bundle)} for more details. |
3212 | 3211 | * |
3213 | 3212 | * @throws android.content.ActivityNotFoundException |
3214 | 3213 | * |
@@ -3288,7 +3287,10 @@ public void startIntentSenderForResult(IntentSender intent, int requestCode, |
3288 | 3287 | * <var>flagsMask</var> |
3289 | 3288 | * @param extraFlags Always set to 0. |
3290 | 3289 | * @param options Additional options for how the Activity should be started. |
3291 | | - * May be null if there are no options. |
| 3290 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3291 | + * Context.startActivity(Intent, Bundle)} for more details. If options |
| 3292 | + * have also been supplied by the IntentSender, options given here will |
| 3293 | + * override any that conflict with those given by the IntentSender. |
3292 | 3294 | */ |
3293 | 3295 | public void startIntentSenderForResult(IntentSender intent, int requestCode, |
3294 | 3296 | Intent fillInIntent, int flagsMask, int flagsValues, int extraFlags, |
@@ -3369,7 +3371,8 @@ public void startActivity(Intent intent) { |
3369 | 3371 | * |
3370 | 3372 | * @param intent The intent to start. |
3371 | 3373 | * @param options Additional options for how the Activity should be started. |
3372 | | - * May be null if there are no options. |
| 3374 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3375 | + * Context.startActivity(Intent, Bundle)} for more details. |
3373 | 3376 | * |
3374 | 3377 | * @throws android.content.ActivityNotFoundException |
3375 | 3378 | * |
@@ -3417,7 +3420,8 @@ public void startActivities(Intent[] intents) { |
3417 | 3420 | * |
3418 | 3421 | * @param intents The intents to start. |
3419 | 3422 | * @param options Additional options for how the Activity should be started. |
3420 | | - * May be null if there are no options. |
| 3423 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3424 | + * Context.startActivity(Intent, Bundle)} for more details. |
3421 | 3425 | * |
3422 | 3426 | * @throws android.content.ActivityNotFoundException |
3423 | 3427 | * |
@@ -3465,7 +3469,10 @@ public void startIntentSender(IntentSender intent, |
3465 | 3469 | * <var>flagsMask</var> |
3466 | 3470 | * @param extraFlags Always set to 0. |
3467 | 3471 | * @param options Additional options for how the Activity should be started. |
3468 | | - * May be null if there are no options. |
| 3472 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3473 | + * Context.startActivity(Intent, Bundle)} for more details. If options |
| 3474 | + * have also been supplied by the IntentSender, options given here will |
| 3475 | + * override any that conflict with those given by the IntentSender. |
3469 | 3476 | */ |
3470 | 3477 | public void startIntentSender(IntentSender intent, |
3471 | 3478 | Intent fillInIntent, int flagsMask, int flagsValues, int extraFlags, |
@@ -3521,7 +3528,8 @@ public boolean startActivityIfNeeded(Intent intent, int requestCode) { |
3521 | 3528 | * onActivityResult() when the activity exits, as described in |
3522 | 3529 | * {@link #startActivityForResult}. |
3523 | 3530 | * @param options Additional options for how the Activity should be started. |
3524 | | - * May be null if there are no options. |
| 3531 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3532 | + * Context.startActivity(Intent, Bundle)} for more details. |
3525 | 3533 | * |
3526 | 3534 | * @return If a new activity was launched then true is returned; otherwise |
3527 | 3535 | * false is returned and you must handle the Intent yourself. |
@@ -3592,7 +3600,8 @@ public boolean startNextMatchingActivity(Intent intent) { |
3592 | 3600 | * your own activity; the only changes you can make are to the extras |
3593 | 3601 | * inside of it. |
3594 | 3602 | * @param options Additional options for how the Activity should be started. |
3595 | | - * May be null if there are no options. |
| 3603 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3604 | + * Context.startActivity(Intent, Bundle)} for more details. |
3596 | 3605 | * |
3597 | 3606 | * @return Returns a boolean indicating whether there was another Activity |
3598 | 3607 | * to start: true if there was a next activity to start, false if there |
@@ -3644,7 +3653,8 @@ public void startActivityFromChild(Activity child, Intent intent, |
3644 | 3653 | * @param intent The intent to start. |
3645 | 3654 | * @param requestCode Reply request code. < 0 if reply is not requested. |
3646 | 3655 | * @param options Additional options for how the Activity should be started. |
3647 | | - * May be null if there are no options. |
| 3656 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3657 | + * Context.startActivity(Intent, Bundle)} for more details. |
3648 | 3658 | * |
3649 | 3659 | * @throws android.content.ActivityNotFoundException |
3650 | 3660 | * |
@@ -3694,7 +3704,8 @@ public void startActivityFromFragment(Fragment fragment, Intent intent, |
3694 | 3704 | * @param intent The intent to start. |
3695 | 3705 | * @param requestCode Reply request code. < 0 if reply is not requested. |
3696 | 3706 | * @param options Additional options for how the Activity should be started. |
3697 | | - * May be null if there are no options. |
| 3707 | + * See {@link android.content.Context#startActivity(Intent, Bundle) |
| 3708 | + * Context.startActivity(Intent, Bundle)} for more details. |
3698 | 3709 | * |
3699 | 3710 | * @throws android.content.ActivityNotFoundException |
3700 | 3711 | * |
@@ -3744,6 +3755,14 @@ public void startIntentSenderFromChild(Activity child, IntentSender intent, |
3744 | 3755 | * Call immediately after one of the flavors of {@link #startActivity(Intent)} |
3745 | 3756 | * or {@link #finish} to specify an explicit transition animation to |
3746 | 3757 | * perform next. |
| 3758 | + * |
| 3759 | + * <p>As of {@link android.os.Build.VERSION_CODES#JELLY_BEAN} an alternative |
| 3760 | + * to using this with starting activities is to supply the desired animation |
| 3761 | + * information through a {@link ActivityOptions} bundle to |
| 3762 | + * {@link #startActivity(Intent, Bundle) or a related function. This allows |
| 3763 | + * you to specify a custom animation even when starting an activity from |
| 3764 | + * outside the context of the current top activity. |
| 3765 | + * |
3747 | 3766 | * @param enterAnim A resource ID of the animation resource to use for |
3748 | 3767 | * the incoming activity. Use 0 for no animation. |
3749 | 3768 | * @param exitAnim A resource ID of the animation resource to use for |
@@ -4065,7 +4084,7 @@ public PendingIntent createPendingResult(int requestCode, Intent data, |
4065 | 4084 | ActivityManagerNative.getDefault().getIntentSender( |
4066 | 4085 | ActivityManager.INTENT_SENDER_ACTIVITY_RESULT, packageName, |
4067 | 4086 | mParent == null ? mToken : mParent.mToken, |
4068 | | - mEmbeddedID, requestCode, new Intent[] { data }, null, flags); |
| 4087 | + mEmbeddedID, requestCode, new Intent[] { data }, null, flags, null); |
4069 | 4088 | return target != null ? new PendingIntent(target) : null; |
4070 | 4089 | } catch (RemoteException e) { |
4071 | 4090 | // Empty |
|
0 commit comments