diff options
Diffstat (limited to 'core/java/android/os/PowerManager.java')
| -rw-r--r-- | core/java/android/os/PowerManager.java | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/core/java/android/os/PowerManager.java b/core/java/android/os/PowerManager.java index e0c621e560e8..9eb7fe31a0f4 100644 --- a/core/java/android/os/PowerManager.java +++ b/core/java/android/os/PowerManager.java @@ -1613,6 +1613,21 @@ public final class PowerManager { } /** + * Forces the device to wake up from sleep only if nothing is blocking the proximity sensor. + * + * @see #wakeUp + * + * @hide + */ + public void wakeUpWithProximityCheck(long time, @WakeReason int reason, String details) { + try { + mService.wakeUpWithProximityCheck(time, reason, details, mContext.getOpPackageName()); + } catch (RemoteException e) { + throw e.rethrowFromSystemServer(); + } + } + + /** * Forces the device to start napping. * <p> * If the device is currently awake, starts dreaming, otherwise does nothing. |
