ForceDoze icon indicating copy to clipboard operation
ForceDoze copied to clipboard

Service updates

Open Almoped opened this issue 9 years ago • 1 comments

Seems to include scrolling updates aswell (I am new to git), anyways.

These are the changes I've made to ForceDozeService.java in an attempt to make the service work correctly. The (could be) constant kept wakelocks seems to have been fixed. One time I've had a stray timertask fire, I still havent figured out how it happened.

In addition I've changed the doze delay to seconds, as minutes didn't seems to make much sence. Added a few debug strings. Added a wifi timout option.

Almoped avatar Aug 25 '16 00:08 Almoped

A couple of things that needs changes before I merge this:

  1. Strings in prefs.xml needs to be in strings.xml
  2. WiFi timeout shouldn't be an option, as I think it may confuse users plus having too many options in the app should be avoided. Also, maintenance periods don't last for more than 5 mins so I would suggest it should work like this: a) If in maintenance period, try reconnecting to WiFi if it doesn't connect automatically in 15 seconds. If it still doesn't connect, then try 3 times with 15 second intervals. b) If device goes out of Doze (due to screen on), try reconnecting to WiFi if it doesn't connect automatically in 15 seconds. If it still doesn't connect, then leave it. There's no need to manage retries, the user can toggle WiFi on/off by themselves if it doesn't work after 1 retry.

Also, service related commits need testing on Nougat ,so you'll have to first update your master branch and then apply these changes, and then test them before submitting.

theblixguy avatar Feb 26 '17 23:02 theblixguy