Phonegap camera crash on android 4.1.2, samsung galaxy s3, HTC -
i think lot of developers familier problem of phonegap crashes/restarts after getting picture camera / library on android 4.1.2.
after many searches of many solutions want put order problem , wish me understand current solution. note: current stable phonegap version 2.9.0.
using fileuri , not dataurl, because encoded base64 big dom handle.
editing (not via phonegap build config.xml) android manifest file , add following line every activity:
android:alwaysretaintaskstate="true" android:launchmode="singletask".
limit resolution using targetwidth/targetheight, because image big causes memory on load. , reducing quality..
switch off
"do not keep actitivies"
option in android settings.. ofcourse not real solutions becaues can't ask users that..
- again, editing android manifest (with discarding phonegap build service) , add:
android:configchanges="orientation|keyboardhidden|keyboard|screensize|locale" <uses-feature android:name="android.hardware.camera" android:required="false"/> <uses-sdk android:minsdkversion="7" android:targetsdkversion="10"/> <activity android:configchanges="orientation|keyboardhidden" />
- using external camera plugin (not phonegap's):
links these solutions here: http://community.phonegap.com/nitobi/topics/phonegap_camera_crash_on_android_4_1_2_samsung_galaxy_s3_htc
now.. after literature review.. know combination works? please help!
i had similar problem. require following work: make sure "uses-feature" tag appears after "application" tag.
<uses-feature android:name="android.hardware.camera" android:required="false"/> <uses-feature android:name="android.hardware.camera.autofocus" android:required="false"/> <application ......
i hope resolves issue.
Comments
Post a Comment