summaryrefslogtreecommitdiffstats
path: root/src/com/android/camera/ui/IndicatorControl.java
diff options
context:
space:
mode:
authorChih-yu Huang <akahuang@google.com>2011-10-07 18:44:53 +0800
committerChih-yu Huang <akahuang@google.com>2011-10-14 12:25:58 +0800
commit3ebe49d8f1b4defb7cfd4850a14e795aada2ebd1 (patch)
tree67f06a39d74ad8f731cc1583954ac563ad4e87cf /src/com/android/camera/ui/IndicatorControl.java
parent1003bbc8bfa6dd241af7bbb5f124a9940ba4cc32 (diff)
downloadLegacyCamera-3ebe49d8f1b4defb7cfd4850a14e795aada2ebd1.zip
LegacyCamera-3ebe49d8f1b4defb7cfd4850a14e795aada2ebd1.tar.gz
LegacyCamera-3ebe49d8f1b4defb7cfd4850a14e795aada2ebd1.tar.bz2
Rename function "setDegree" to "setOrientation".
bug:5244256 Change-Id: I6f5c96a5e1fefab5fa09a12fd3a0cf169bcbc6f5
Diffstat (limited to 'src/com/android/camera/ui/IndicatorControl.java')
-rw-r--r--src/com/android/camera/ui/IndicatorControl.java14
1 files changed, 6 insertions, 8 deletions
diff --git a/src/com/android/camera/ui/IndicatorControl.java b/src/com/android/camera/ui/IndicatorControl.java
index 86b0cc9..cac38b8 100644
--- a/src/com/android/camera/ui/IndicatorControl.java
+++ b/src/com/android/camera/ui/IndicatorControl.java
@@ -35,7 +35,7 @@ import java.util.ArrayList;
* A view that contains camera setting indicators.
*/
public abstract class IndicatorControl extends RelativeLayout implements
- IndicatorButton.Listener, OtherSettingsPopup.Listener {
+ IndicatorButton.Listener, OtherSettingsPopup.Listener, Rotatable {
private static final String TAG = "IndicatorControl";
public static final int MODE_CAMERA = 0;
public static final int MODE_VIDEO = 1;
@@ -45,7 +45,7 @@ public abstract class IndicatorControl extends RelativeLayout implements
protected CameraPicker mCameraPicker;
private PreferenceGroup mPreferenceGroup;
- private int mDegree = 0;
+ private int mOrientation = 0;
protected int mCurrentMode = MODE_CAMERA;
@@ -61,15 +61,13 @@ public abstract class IndicatorControl extends RelativeLayout implements
super(context, attrs);
}
- public void setDegree(int degree) {
- mDegree = degree;
+ public void setOrientation(int orientation) {
+ mOrientation = orientation;
int count = getChildCount();
for (int i = 0 ; i < count ; ++i) {
View view = getChildAt(i);
- if (view instanceof RotateImageView) {
- ((RotateImageView) view).setDegree(degree);
- } else if (view instanceof ZoomControl) {
- ((ZoomControl) view).setDegree(degree);
+ if (view instanceof Rotatable) {
+ ((Rotatable) view).setOrientation(orientation);
}
}
}