Skip to content

Commit 5573ac0

Browse files
Wu-cheng LiAndroid (Google) Code Review
authored andcommitted
Merge "Unhide camera autofocus move callback."
2 parents 069c4f3 + 6574539 commit 5573ac0

File tree

2 files changed

+10
-7
lines changed

2 files changed

+10
-7
lines changed

api/current.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9453,6 +9453,7 @@ package android.hardware {
94539453
method public static android.hardware.Camera open();
94549454
method public final void reconnect() throws java.io.IOException;
94559455
method public final void release();
9456+
method public void setAutoFocusMoveCallback(android.hardware.Camera.AutoFocusMoveCallback);
94569457
method public final void setDisplayOrientation(int);
94579458
method public final void setErrorCallback(android.hardware.Camera.ErrorCallback);
94589459
method public final void setFaceDetectionListener(android.hardware.Camera.FaceDetectionListener);
@@ -9488,6 +9489,10 @@ package android.hardware {
94889489
method public abstract void onAutoFocus(boolean, android.hardware.Camera);
94899490
}
94909491

9492+
public static abstract interface Camera.AutoFocusMoveCallback {
9493+
method public abstract void onAutoFocusMoving(boolean, android.hardware.Camera);
9494+
}
9495+
94919496
public static class Camera.CameraInfo {
94929497
ctor public Camera.CameraInfo();
94939498
field public static final int CAMERA_FACING_BACK = 0; // 0x0

core/java/android/hardware/Camera.java

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -950,19 +950,18 @@ public final void cancelAutoFocus()
950950
/**
951951
* Callback interface used to notify on auto focus start and stop.
952952
*
953-
* <p>This is useful for continuous autofocus -- {@link Parameters#FOCUS_MODE_CONTINUOUS_VIDEO}
954-
* and {@link Parameters#FOCUS_MODE_CONTINUOUS_PICTURE}. Applications can
955-
* show autofocus animation.</p>
956-
*
957-
* @hide
953+
* <p>This is only supported in continuous autofocus modes -- {@link
954+
* Parameters#FOCUS_MODE_CONTINUOUS_VIDEO} and {@link
955+
* Parameters#FOCUS_MODE_CONTINUOUS_PICTURE}. Applications can show
956+
* autofocus animation based on this.</p>
958957
*/
959958
public interface AutoFocusMoveCallback
960959
{
961960
/**
962961
* Called when the camera auto focus starts or stops.
963962
*
964963
* @param start true if focus starts to move, false if focus stops to move
965-
* @param camera the Camera service object
964+
* @param camera the Camera service object
966965
*/
967966
void onAutoFocusMoving(boolean start, Camera camera);
968967
}
@@ -971,7 +970,6 @@ public interface AutoFocusMoveCallback
971970
* Sets camera auto-focus move callback.
972971
*
973972
* @param cb the callback to run
974-
* @hide
975973
*/
976974
public void setAutoFocusMoveCallback(AutoFocusMoveCallback cb) {
977975
mAutoFocusMoveCallback = cb;

0 commit comments

Comments
 (0)