Merge "PowerManager: Adds isSustainedPerformanceModeSupported()" into nyc-dev
am: a68fe1e * commit 'a68fe1e4d3a34667e5948912c53290298388427b': PowerManager: Adds isSustainedPerformanceModeSupported() Change-Id: Ief02f71f1230fda43386628d1d263800e5bab6d6
This commit is contained in:
@@ -29074,6 +29074,7 @@ package android.os {
|
||||
method public boolean isInteractive();
|
||||
method public boolean isPowerSaveMode();
|
||||
method public deprecated boolean isScreenOn();
|
||||
method public boolean isSustainedPerformanceModeSupported();
|
||||
method public boolean isWakeLockLevelSupported(int);
|
||||
method public android.os.PowerManager.WakeLock newWakeLock(int, java.lang.String);
|
||||
method public void reboot(java.lang.String);
|
||||
|
||||
@@ -31307,6 +31307,7 @@ package android.os {
|
||||
method public boolean isPowerSaveMode();
|
||||
method public boolean isScreenBrightnessBoosted();
|
||||
method public deprecated boolean isScreenOn();
|
||||
method public boolean isSustainedPerformanceModeSupported();
|
||||
method public boolean isWakeLockLevelSupported(int);
|
||||
method public android.os.PowerManager.WakeLock newWakeLock(int, java.lang.String);
|
||||
method public void reboot(java.lang.String);
|
||||
|
||||
@@ -29139,6 +29139,7 @@ package android.os {
|
||||
method public boolean isInteractive();
|
||||
method public boolean isPowerSaveMode();
|
||||
method public deprecated boolean isScreenOn();
|
||||
method public boolean isSustainedPerformanceModeSupported();
|
||||
method public boolean isWakeLockLevelSupported(int);
|
||||
method public android.os.PowerManager.WakeLock newWakeLock(int, java.lang.String);
|
||||
method public void reboot(java.lang.String);
|
||||
|
||||
@@ -1030,6 +1030,16 @@ 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 #SUSTAINED_PERFORMANCE_WAKE_LOCK}.
|
||||
*/
|
||||
public boolean isSustainedPerformanceModeSupported() {
|
||||
return mContext.getResources().getBoolean(
|
||||
com.android.internal.R.bool.config_sustainedPerformanceModeSupported);
|
||||
}
|
||||
|
||||
/**
|
||||
* Intent that is broadcast when the state of {@link #isPowerSaveMode()} changes.
|
||||
* This broadcast is only sent to registered receivers.
|
||||
|
||||
@@ -2507,4 +2507,7 @@
|
||||
<!-- True if the device requires AppWidgetService even if it does not have
|
||||
the PackageManager.FEATURE_APP_WIDGETS feature -->
|
||||
<bool name="config_enableAppWidgetService">false</bool>
|
||||
|
||||
<!-- True if the device supports Sustained Performance Mode-->
|
||||
<bool name="config_sustainedPerformanceModeSupported">false</bool>
|
||||
</resources>
|
||||
|
||||
@@ -2542,4 +2542,6 @@
|
||||
|
||||
<java-symbol type="id" name="textSpacerNoTitle" />
|
||||
<java-symbol type="id" name="titleDividerNoCustom" />
|
||||
|
||||
<java-symbol type="bool" name="config_sustainedPerformanceModeSupported" />
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user