Since Android 6.0, we need to request permissions during app runtime.
In my app, i'm using local storage, camera, geolocation and audio recording permissions.
So, requesting for local storage, camera and geolocation is ok with that snippet :
https://github.com/appcelerator-developer-relations/appc-sample-ti510/blob/master/app/controllers/permissions.js
But i've not found how to request for audio recording permission...I actually use titutorial.audiorecorder module for Android and it crashes when i tried to record since Android 6.0 because permission for recording is not enable.
More informations on my environment :
Operating System
Name = Mac OS X
Version = 10.11.3
Architecture = 64bit
# CPUs = 4
Memory = 17179869184
Node.js
Node.js Version = 0.12.7
npm Version = 2.11.3
Titanium CLI
CLI Version = 5.0.6
Titanium SDK
SDK Version = 5.2.0.GA
SDK Path = /Users/****/#/mobilesdk/osx/5.2.0.GA
Target Platform = android
Appcelerator Studio 4.5.0.201602170821
tiapp.xml
<manifest>
<uses-sdk android:minSdkVersion="15"/>
<uses-sdk android:targetSdkVersion="23"/>
<uses-permission android:name="android.permission.RECORD_AUDIO"/>
<uses-permission android:name="android.permission.CAPTURE_AUDIO_OUTPUT"/>
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.WRITE_INTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>
<uses-feature android:glEsVersion="0x00020000" android:required="true"/>
<uses-permission android:name="com.mycompany.myapp.permission.MAPS_RECEIVE"/>
...
...
</manifest>
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…