Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-28051] Android: Add foreground service type constants for "camera" and "microphone"

GitHub Issuen/a
TypeNew Feature
PriorityLow
StatusClosed
ResolutionFixed
Resolution Date2020-11-30T18:55:06.000+0000
Affected Version/sn/a
Fix Version/sRelease 9.3.0
ComponentsAndroid
Labelsandroid, audio, audioRecording, camera, service
ReporterJoshua Quick
AssigneeJoshua Quick
Created2020-07-25T02:10:33.000+0000
Updated2020-11-30T18:55:07.000+0000

Description

*Summary:* Android 11 has added the following... * [ServiceInfo.FOREGROUND_SERVICE_TYPE_CAMERA](https://developer.android.com/reference/android/content/pm/ServiceInfo#FOREGROUND_SERVICE_TYPE_CAMERA) * [ServiceInfo.FOREGROUND_SERVICE_TYPE_MICROPHONE](https://developer.android.com/reference/android/content/pm/ServiceInfo#FOREGROUND_SERVICE_TYPE_MICROPHONE) We should add the above to Titanium as constants... * Ti.Android.FOREGROUND_SERVICE_TYPE_CAMERA * Ti.Android.FOREGROUND_SERVICE_TYPE_MICROPHONE *Note:* These constants are to be passed to Titanium's [Service.foregroundNotify()](https://docs.appcelerator.com/platform/latest/#!/api/Titanium.Android.Service-method-foregroundNotify) method which gives that foreground service permission to use these feature while the app is in the background.

Comments

  1. Joshua Quick 2020-08-29

    PR (9.3.x): https://github.com/appcelerator/titanium_mobile/pull/11986
  2. Satyam Sekhri 2020-10-07

    FR Passed Waiting for Jenkins build

JSON Source