Control screen brightness in android using “ Background Service”

情到浓时终转凉″ 提交于 2019-12-29 05:00:06

问题


Problem:-

I want to control the brightness of screen using a background service in android.

Existing Solutions:-

There are similar question posted in the form in below link:-

Adding screen brightness controls to android application

Why existing solution will not work?

All the solution provided in the link works well with an Activity, but I want to write a Background Service which controls the brightness of the screen.

So can you someone please help me find a solution on this issue.

Thanks in advance


回答1:


From your service, start an activity and finish() it real fast!



来源:https://stackoverflow.com/questions/2222146/control-screen-brightness-in-android-using-background-service

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!