Skip to main content
Version: v2

getAutoBrightness

Start from API_LEVEL 2.0 . Please refer to API_LEVEL.

Get whether to turn on the screen auto brightness setting.

Type

function getAutoBrightness(): Result

Parameters

Result

TypeDescription
booleantrue - auto-brightness is set to on, false - auto-brightness is set to off

Example

import { getAutoBrightness } from '@zos/display'

const result = getAutoBrightness()

if (result) {
console.log('Auto brightness setting is turned on')
}