summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Ruchi Kandoi <kandoiruchi@google.com> 2016-05-27 16:20:42 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2016-05-27 16:20:43 +0000
commit7730e57dc6624a66cdc35260f855a467fadc7b04 (patch)
treedf1f2b5783c27470ff40bb4ead8a2bee7dcbea98
parent83e50327fcf24e4d17a341cc2efaafc95046a8f9 (diff)
parentc45908d19612e6ccc014b19f5963d06dbe066028 (diff)
Merge "PowerManager: Adds Documentation to isSustainedPerformanceModeSupported()" into nyc-dev
-rw-r--r--core/java/android/os/PowerManager.java16
1 files changed, 13 insertions, 3 deletions
diff --git a/core/java/android/os/PowerManager.java b/core/java/android/os/PowerManager.java
index c285acbc271b..ce7a1243fe7a 100644
--- a/core/java/android/os/PowerManager.java
+++ b/core/java/android/os/PowerManager.java
@@ -1021,9 +1021,19 @@ public final class PowerManager {
}
/**
- * Returns True if the device supports Sustained Performance Mode.
- * Applications Should check if the device supports this mode, before
- * using {@link android.view.Window#setSustainedPerformanceMode}.
+ * This function checks if the device has implemented Sustained Performance
+ * Mode. This needs to be checked only once and is constant for a particular
+ * device/release.
+ *
+ * Sustained Performance Mode is intended to provide a consistent level of
+ * performance for prolonged amount of time.
+ *
+ * Applications should check if the device supports this mode, before using
+ * {@link android.view.Window#setSustainedPerformanceMode}.
+ *
+ * @return Returns True if the device supports it, false otherwise.
+ *
+ * @see android.view.Window#setSustainedPerformanceMode
*/
public boolean isSustainedPerformanceModeSupported() {
return mContext.getResources().getBoolean(