summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/com/android/camera/VideoModule.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/com/android/camera/VideoModule.java b/src/com/android/camera/VideoModule.java
index e651843be..d5351e297 100644
--- a/src/com/android/camera/VideoModule.java
+++ b/src/com/android/camera/VideoModule.java
@@ -1728,6 +1728,12 @@ public class VideoModule implements CameraModule,
private void saveVideo() {
if (mVideoFileDescriptor == null) {
+ //use the recording stop timestamp to generate the video's file name.
+ String videoSourcePath = mVideoFilename;
+ generateVideoFilename(mProfile.fileFormat);
+ mCurrentVideoFilename = mVideoFilename;
+ File sourceFile = new File(videoSourcePath);
+ sourceFile.renameTo(new File(mCurrentVideoFilename));
File origFile = new File(mCurrentVideoFilename);
if (!origFile.exists() || origFile.length() <= 0) {
Log.e(TAG, "Invalid file");