appium / WebDriverAgent

A WebDriver server for iOS and tvOS
Other
1.19k stars 371 forks source link

I want to keep the current screen brightness after starting wda. Is this possible? Currently, wda does not run after opening it, and the screen will automatically dim after a while. #902

Open 18002138971 opened 4 months ago

18002138971 commented 4 months ago

I want to keep the current screen brightness after starting wda. Is this possible? Currently, wda does not run after opening it, and the screen will automatically dim after a while.

KazuCocoa commented 4 months ago

Does it mean the brightness value in Settings -> Display & Brightness? Or "Automation Running Hold both volume buttons to stop" and grey overlay thing? The grey overlay is iOS's limitation so it's not possible to avoid.

For the brightness option, I don't know UI Automation something could affect the value. You may be able to disable the automatic adjustment from settings -> accessibility -> display & text size -> turn auto-brightness off.

18002138971 commented 4 months ago

I think this is when WDA itself has no Ui operation, it is in the background state, and is subject to the system power settings, which will cause its own interface to darken and become a gray interface. So can I solve this problem by keeping it active in the foreground?

KazuCocoa commented 4 months ago

Have you tried the below?

settings -> accessibility -> display & text size -> turn auto-brightness off.

So can I solve this problem by keeping it active in the foreground?

I don't know. I haven't tried, but the foreground means the black screen by WDA keeps on the top.

18002138971 commented 4 months ago

settings -> accessibility -> display & text size -> turn auto-brightness off. I tried it but it didn't work. and I needed to test the system's automatic brightness function, so I wanted to avoid the impact caused by the wda page. Can't turn off auto-brightness

KazuCocoa commented 4 months ago

Then, I have no idea. It possibly depends on iOS internal handling so Apps like WDA may not be controllable.