summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanny Baumann <dannybaumann@web.de>2013-04-05 13:42:57 +0200
committerDanny Baumann <dannybaumann@web.de>2013-04-05 13:42:57 +0200
commitf15a419e70a51518e2c68e837c09c15fef09e721 (patch)
tree72ecbb72e3d7ea328529a0755790138d19d62b60
parent9658de2df79f6472dd0728d50074e27a3553637d (diff)
downloadframeworks_base-f15a419e70a51518e2c68e837c09c15fef09e721.zip
frameworks_base-f15a419e70a51518e2c68e837c09c15fef09e721.tar.gz
frameworks_base-f15a419e70a51518e2c68e837c09c15fef09e721.tar.bz2
Fix documentation of requestCode parameter.
It's not correct to state requestCode is 'currently not used'. It can be used to differentiate multiple PendingIntents since a number of Android versions now. Also, the introduction block of the PendingIntent documentation explicitly states this as a possible use: "If you truly need multiple distinct PendingIntent objects active at the same time [...], then you will need to ensure there is something that is different about them to associate them with different PendingIntents. This may be any of the Intent attributes considered by Intent.filterEquals, or different request code integers supplied [...]" So fix the documentation inconsistency to make the possible use immediately clear. Change-Id: Ia65d7a5ab12c2c3ee1aa1c5107e5ea8fd937b765
-rw-r--r--core/java/android/app/PendingIntent.java18
1 files changed, 6 insertions, 12 deletions
diff --git a/core/java/android/app/PendingIntent.java b/core/java/android/app/PendingIntent.java
index 2897ee0..97de4f4 100644
--- a/core/java/android/app/PendingIntent.java
+++ b/core/java/android/app/PendingIntent.java
@@ -202,8 +202,7 @@ public final class PendingIntent implements Parcelable {
*
* @param context The Context in which this PendingIntent should start
* the activity.
- * @param requestCode Private request code for the sender (currently
- * not used).
+ * @param requestCode Private request code for the sender
* @param intent Intent of the activity to be launched.
* @param flags May be {@link #FLAG_ONE_SHOT}, {@link #FLAG_NO_CREATE},
* {@link #FLAG_CANCEL_CURRENT}, {@link #FLAG_UPDATE_CURRENT},
@@ -229,8 +228,7 @@ public final class PendingIntent implements Parcelable {
*
* @param context The Context in which this PendingIntent should start
* the activity.
- * @param requestCode Private request code for the sender (currently
- * not used).
+ * @param requestCode Private request code for the sender
* @param intent Intent of the activity to be launched.
* @param flags May be {@link #FLAG_ONE_SHOT}, {@link #FLAG_NO_CREATE},
* {@link #FLAG_CANCEL_CURRENT}, {@link #FLAG_UPDATE_CURRENT},
@@ -315,8 +313,7 @@ public final class PendingIntent implements Parcelable {
*
* @param context The Context in which this PendingIntent should start
* the activity.
- * @param requestCode Private request code for the sender (currently
- * not used).
+ * @param requestCode Private request code for the sender
* @param intents Array of Intents of the activities to be launched.
* @param flags May be {@link #FLAG_ONE_SHOT}, {@link #FLAG_NO_CREATE},
* {@link #FLAG_CANCEL_CURRENT}, {@link #FLAG_UPDATE_CURRENT},
@@ -361,8 +358,7 @@ public final class PendingIntent implements Parcelable {
*
* @param context The Context in which this PendingIntent should start
* the activity.
- * @param requestCode Private request code for the sender (currently
- * not used).
+ * @param requestCode Private request code for the sender
* @param intents Array of Intents of the activities to be launched.
* @param flags May be {@link #FLAG_ONE_SHOT}, {@link #FLAG_NO_CREATE},
* {@link #FLAG_CANCEL_CURRENT}, {@link #FLAG_UPDATE_CURRENT},
@@ -425,8 +421,7 @@ public final class PendingIntent implements Parcelable {
*
* @param context The Context in which this PendingIntent should perform
* the broadcast.
- * @param requestCode Private request code for the sender (currently
- * not used).
+ * @param requestCode Private request code for the sender
* @param intent The Intent to be broadcast.
* @param flags May be {@link #FLAG_ONE_SHOT}, {@link #FLAG_NO_CREATE},
* {@link #FLAG_CANCEL_CURRENT}, {@link #FLAG_UPDATE_CURRENT},
@@ -475,8 +470,7 @@ public final class PendingIntent implements Parcelable {
*
* @param context The Context in which this PendingIntent should start
* the service.
- * @param requestCode Private request code for the sender (currently
- * not used).
+ * @param requestCode Private request code for the sender
* @param intent An Intent describing the service to be started.
* @param flags May be {@link #FLAG_ONE_SHOT}, {@link #FLAG_NO_CREATE},
* {@link #FLAG_CANCEL_CURRENT}, {@link #FLAG_UPDATE_CURRENT},