SimpleMobileTools / Simple-Clock

Combination of a beautiful clock with widget, alarm, stopwatch & timer, no ads
https://www.simplemobiletools.com
GNU General Public License v3.0
588 stars 237 forks source link

Refactor of `showOverLockscreen` function #470

Closed rawlin closed 1 year ago

rawlin commented 1 year ago

I was not able to reproduce the issue of needing to unlock my phone to see the alarm with USB cable connected and USB debugging on. (Tested on Samsung Note 9 - Android 13 & Xiaomi Redmi Note 10 - Android 11)

However, looking at this StackOverflow answer https://stackoverflow.com/a/55998126/13908824, I've moved the window flag manipulation part of the showOverLockscreen function to the else block which executes only if the OS version is less than 27 which was otherwise executing for both cases i.e above and below SDK 27.

I'm not sure if this will fix the issue of needing to unlock the phone for the alarm as I'm not able to reproduce it on my end

tibbi commented 1 year ago

nope, this hasnt fixed it. Will try playing around with it if you cannot reproduce it.