使用系統提供的組件(MediaStore.ACTION_IMAGE_CAPTURE)拍攝照片很常見。令人沮喪但很常見的SNAPSHOT問題!
正如我ve experimented, with a certain rate the android system will kill the snapshot calling Activity to prevent memory related exception, and the calling activity will be created again where returned. Thus I have to save the states of the calling Activity via onSaveInstanceState, and retrieve them via onRestoreInstanceState. (If I
中號不正確,而且有進一步信息,請指出來)
不過,我也發現,當殺戮發生時,存儲在RAM中的所有我的信息被擦除,RESETED,例如那些Singleton類類型的對象,或靜態類及其字段!
這種機制是如此令人沮喪,如何處理這種情況?