summaryrefslogtreecommitdiff
path: root/core/java/android
diff options
context:
space:
mode:
authorDiego Vela <diegovela@google.com>2020-04-21 16:22:47 -0700
committerDiego Vela <diegovela@google.com>2020-04-27 15:10:18 +0000
commit6e99bfcd6cc8462d32739a6397996a36e6408360 (patch)
tree36a7945d9708a9c72b3f6d73552ad0402671d5b4 /core/java/android
parent53e927f890f08d7916ccf1ae2afeb2624561d107 (diff)
Update Documentation for onActivityResult.
Update doc to be more accurate about when onActivityResult is called Bug: 140608415 Test: n/a Change-Id: If44b02719e18b3107b064d749396d896bed08f86
Diffstat (limited to 'core/java/android')
-rw-r--r--core/java/android/app/Activity.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/core/java/android/app/Activity.java b/core/java/android/app/Activity.java
index 6480a6abeb78..e0ae750ba5ee 100644
--- a/core/java/android/app/Activity.java
+++ b/core/java/android/app/Activity.java
@@ -6549,8 +6549,12 @@ public class Activity extends ContextThemeWrapper
* {@link #RESULT_CANCELED} if the activity explicitly returned that,
* didn't return any result, or crashed during its operation.
*
- * <p>You will receive this call immediately before onResume() when your
- * activity is re-starting.
+ * <p>An activity can never receive a result in the resumed state. You can count on
+ * {@link #onResume} being called after this method, though not necessarily immediately after.
+ * If the activity was resumed, it will be paused and the result will be delivered, followed
+ * by {@link #onResume}. If the activity wasn't in the resumed state, then the result will
+ * be delivered, with {@link #onResume} called sometime later when the activity becomes active
+ * again.
*
* <p>This method is never invoked if your activity sets
* {@link android.R.styleable#AndroidManifestActivity_noHistory noHistory} to