summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--res/drawable-hdpi/border_preview_time_lapse.9.pngbin0 -> 447 bytes
-rw-r--r--res/drawable-mdpi/border_preview_time_lapse.9.pngbin0 -> 447 bytes
-rw-r--r--src/com/android/camera/VideoCamera.java19
3 files changed, 14 insertions, 5 deletions
diff --git a/res/drawable-hdpi/border_preview_time_lapse.9.png b/res/drawable-hdpi/border_preview_time_lapse.9.png
new file mode 100644
index 0000000..495a986
--- /dev/null
+++ b/res/drawable-hdpi/border_preview_time_lapse.9.png
Binary files differ
diff --git a/res/drawable-mdpi/border_preview_time_lapse.9.png b/res/drawable-mdpi/border_preview_time_lapse.9.png
new file mode 100644
index 0000000..495a986
--- /dev/null
+++ b/res/drawable-mdpi/border_preview_time_lapse.9.png
Binary files differ
diff --git a/src/com/android/camera/VideoCamera.java b/src/com/android/camera/VideoCamera.java
index 725f133..62984dc 100644
--- a/src/com/android/camera/VideoCamera.java
+++ b/src/com/android/camera/VideoCamera.java
@@ -183,6 +183,7 @@ public class VideoCamera extends NoSearchActivity
// Default 0. If it is larger than 0, the camcorder is in time lapse mode.
private int mTimeBetweenTimeLapseFrameCaptureMs = 0;
private View mTimeLapseLabel;
+ private View mPreviewBorder;
private int mDesiredPreviewWidth;
private int mDesiredPreviewHeight;
@@ -381,6 +382,7 @@ public class VideoCamera extends NoSearchActivity
mRecordingTimeView = (TextView) findViewById(R.id.recording_time);
mOrientationListener = new MyOrientationEventListener(VideoCamera.this);
mTimeLapseLabel = findViewById(R.id.time_lapse_label);
+ mPreviewBorder = findViewById(R.id.preview_border);
// Make sure preview is started.
try {
@@ -393,7 +395,7 @@ public class VideoCamera extends NoSearchActivity
// ignore
}
- showTimeLapseLabel(mCaptureTimeLapse);
+ showTimeLapseUI(mCaptureTimeLapse);
resizeForPreviewAspectRatio();
mBackCameraId = CameraHolder.instance().getBackCameraId();
@@ -1852,13 +1854,20 @@ public class VideoCamera extends NoSearchActivity
setCameraParameters();
}
}
- showTimeLapseLabel(mCaptureTimeLapse);
+ showTimeLapseUI(mCaptureTimeLapse);
}
}
- private void showTimeLapseLabel(boolean enable) {
- if (mTimeLapseLabel == null) return;
- mTimeLapseLabel.setVisibility(enable ? View.VISIBLE : View.INVISIBLE);
+ private void showTimeLapseUI(boolean enable) {
+ if (mTimeLapseLabel != null) {
+ mTimeLapseLabel.setVisibility(enable ? View.VISIBLE : View.INVISIBLE);
+ }
+ if (mPreviewBorder != null) {
+ mPreviewBorder.setBackgroundResource(enable
+ ? R.drawable.border_preview_time_lapse
+ : R.drawable.border_preview);
+ }
+
}
private class MyControlPanelListener implements ControlPanel.Listener {