From af3a19761034225333685b90206dcdb8e784a1c4 Mon Sep 17 00:00:00 2001 From: ztenghui Date: Tue, 17 Sep 2013 16:51:15 -0700 Subject: Delete the captured video if cancel in review. In capture intent case, video get inserted all the time before review. So if cancelled in review mode, the captured video should be deleted. bug:8897671 Change-Id: I01dd4b0707dd1b70480cda94b2a9b9c6ce9194c7 --- src/com/android/camera/VideoModule.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/com/android/camera/VideoModule.java b/src/com/android/camera/VideoModule.java index 56882e1cf..49250d8c8 100644 --- a/src/com/android/camera/VideoModule.java +++ b/src/com/android/camera/VideoModule.java @@ -480,7 +480,10 @@ public class VideoModule implements CameraModule, @OnClickAttr public void onReviewCancelClicked(View v) { mIsInReviewMode = false; - stopVideoRecording(); + // TODO: It should be better to not even insert the URI at all before we + // confirm done in review, which means we need to handle temporary video + // files in a quite different way than we currently had. + mContentResolver.delete(mCurrentVideoUri, null, null); doReturnToCaller(false); } -- cgit v1.2.3