Revision 8177b07f1d519a0376f546fb7b3c0daf27ed17ce authored by kritisingh1 on 27 March 2018, 17:30:54 UTC, committed by kritisingh1 on 20 April 2018, 17:34:00 UTC
1 parent b4cd33a
Raw File
wake-lock.idl
enum WakeLockType {
    "screen",
    "system"
};

partial interface Navigator {
    [SecureContext] Promise<WakeLock> getWakeLock(WakeLockType type);
};

[SecureContext,
 Exposed=Window]
interface WakeLock : EventTarget {
    readonly attribute WakeLockType type;
    readonly attribute boolean      active;
             attribute EventHandler onactivechange;
    WakeLockRequest createRequest();
};

[SecureContext,
 Exposed=Window]
interface WakeLockRequest {
    void cancel();
};
back to top