Use a Foreground Service to collect SMS #8

Open
Workload
Enthousiasm
opened 2 years ago by domi41 · 1 comments
domi41 commented 2 years ago
Owner

When the app is in the background and it gets killed by Android (it may happen at any time), the SMS receiver stops, and no more votes are registered.

Keeping the app in focus helps, but when the phone becomes idle and locks the screen, the app may also be killed at any time, without mercy.

Using a foreground service and an extra thread would probably help, but I'm not sure how the service is supposed to contact the app back if it's been killed.

HELP

Keep in mind that most of the app is a Godot export, and the Android bits are Godot Android Plugins. Perhaps it won't be an issue, but it is a constraint.

When the app is in the background and it gets killed by Android (it may happen at any time), the SMS receiver stops, and no more votes are registered. Keeping the app in focus helps, but when the phone becomes idle and locks the screen, the app may also be killed at any time, without mercy. Using a foreground service and an extra thread would probably help, but I'm not sure how the service is supposed to contact the app back if it's been killed. > HELP Keep in mind that most of the app is a Godot export, and the Android bits are Godot Android Plugins. Perhaps it won't be an issue, but it is a constraint.
domi41 added the
enhancement
help wanted
labels 2 years ago
Poster
Owner

The source of the Android plugin : https://framagit.org/domi41/godot-android-plugin-sms

The source of the Android plugin : https://framagit.org/domi41/godot-android-plugin-sms
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.