是否有事件可检测屏幕变暗? [英] Is there an event to detect when the screen dims?

查看:60
本文介绍了是否有事件可检测屏幕变暗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用SCREEN_DIM_WAKE_LOCK,所以我从不关闭.它只是从全亮度变为暗淡.

I'm using a SCREEN_DIM_WAKE_LOCK and so my never turns off. It just goes from full brightness to dim.

我有什么方法可以检测屏幕何时变暗(事件,接收器等)?

Is there any way for me to detect when the screen gets dim (event, receiver, etc.) ?

推荐答案

据我从Android的源代码可以看到,当屏幕亮度状态更改时,没有广播通知发送.

As far as I can see from Android's source code, there is no broadcast notification send when screen brightness state is changed.

这篇关于是否有事件可检测屏幕变暗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆