In jb2, take a photo/video in camera, and click the thumbnail in the lower right corner/slide to the left to view the image/video, after you click "delete" menu to delete all images/videos, the camera preview is displayed only at about 1/4 on the left of the screen. After sliding to the right, the camera preview interface is displayed. How to automatically return to the cemera preview interface after deleting all content from the "delete" menu The modification method is as follows: (1) In the gallery2 \ SRC \ com \ Android \ gallery3d \ data \ filteremptypromptset. Java file:
@ Override
Public int getmediaitemcount (){
Int itemcount = mbaseset. getmediaitemcount ();
If (itemcount> 0 ){
Return itemcount;
} Else {
Return 0; }
}
(2) In the gallery2 \ SRC \ com \ Android \ gallery3d \ app \ photodataadapter. Java file: Private class updatecontent implements callable <void> { ... Public void call () throws exception { ... If (info. size! = Msize) {
msize = info. size;
If (mcontentend> msize) mcontentend = msize;
If (mactiveend> msize) mactiveend = msize;
}< br> // M: indexhint needs to be limited to [0, msize) If (msize> 0 & info. indexhint> = msize ){
Info. indexhint = mSize-1;
}
... } // End call () ... }