start
The blocker ID that is assigned to this power blocker.
Starts preventing the system from entering lower-power mode. Returns an integer identifying the power save blocker.
!NOTE
prevent-display-sleep
has higher precedence overprevent-app-suspension
. Only the highest precedence type takes effect. In other words,prevent-display-sleep
always takes precedence overprevent-app-suspension
.
For example, an API calling A requests for prevent-app-suspension
, and another calling B requests for prevent-display-sleep
. prevent-display-sleep
will be used until B stops its request. After that, prevent-app-suspension
is used.