Reserving the lights

The ReserveLightL() call reserves the light target(s) exclusively for this client. Multiple lights can be specified by using bitwise-or. A higher priority client may cause lower priority client reservation to be temporarily suspended. Commands can still be issued in suspended state, but they are not acted upon unless suspension is lifted within a specified duration. The suspended client does not get any notification about suspension. If the light target is already reserved by a higher or equal priority application, reserving still succeeds, but the reservation is immediately suspended.

The following code snippet demonstrates how to reserve multiple light targets:

//aRestoreState = ETrue means that any previously frozen state will be restored.
// aForceNoCCoeEnv = EFalse means that the CCoeEnv background/foreground status
// is always used to control further reservations.
iLight->ReserveLightL( ( CHWRMExtendedLight::EPrimaryDisplay | CHWRMExtendedLight::EPrimaryKeyboard ), ETrue, EFalse );