advplyr / audiobookshelf-app

Mobile application for Audiobookshelf
https://audiobookshelf.org
GNU General Public License v3.0
1.08k stars 148 forks source link

[Enhancement]: Keep screen on when reading a ebook #1207

Open samkottler opened 1 month ago

samkottler commented 1 month ago

Describe the Feature/Enhancement

Currently, if the screen lock timeout goes off before I’ve finished reading a “page” my phone/ipad will lock the screen. This requires me to touch the screen periodically to prevent this. It’d be nice if the app automatically prevented screen locking while in the in ebook reader.

Why would this be helpful?

It often takes me longer to read a “page” than the screen lock timeout on my phone/ipad. Keeping the screen on when reading an ebook would prevent this.

Future Implementation (Screenshot)

image

Audiobookshelf App Version

Android App - 0.9.63, iOS App - 0.9.63

Current Implementation (Screenshot)

No response

advplyr commented 1 month ago

This might be better handled by adjusting the screen timeout on the device. I could see adding this feature causing more unexpected permission related issues. What is your screen timeout currently set at? I keep mine at 5 minutes.

samkottler commented 1 month ago

1 minute on my phone and 5 minutes on my iPad. I don’t really want to just adjust the timeout device wide because in every other situation those are the timeouts I want.

I’m not sure about how permissions work, but wouldn’t the app just ask for whatever permission it needs when a user toggles setting? I know other apps are able to prevent screen locking while they’re open.

samkottler commented 1 month ago

It looks like on android at least no permission is required to keep the screen on. I’m not sure about iOS.

citizenxnz commented 1 month ago

I was going to raise the same issue - in any other reader I've used the screen timeout is disabled (it's often a preference flag) - would like to see the same here. Having to remember to push the screen halfway through a page is annoying.

Like @samkottler I don't wish to manually adjust my system systems each time - that is not effortless UX

advplyr commented 1 month ago

@citizenxnz Can you share some mobile apps that have this setting so I can check them out? The Kindle app on Android doesn't have this setting as far as I can find

samkottler commented 1 month ago

The Libby app on android doesn’t allow it to be configured, but does keep the screen on while in the ebook reader.

paulo-erichsen commented 1 week ago

I'm not an android developer, but hopefully some of these links will help

I've also noticed that Moon+ Reader Pro automatically keeps the screen awake when I read ebooks without the need to change any settings which would be a nice UX to see on the Audiobookshelf app. IMO ABS app should automatically enable this for ebooks, but I don't think audiobooks would benefit from this.

Perhaps the change needs to be done somewhere in components/readers or in whatever page that opens the reader?