Skip to content

Commit

Permalink
Rename getVideoSurfaceSize to getSurfaceSize
Browse files Browse the repository at this point in the history
This better matches the callback name (onSurfaceSizeChanged) and
probably cause less confusion with getVideoSize.

PiperOrigin-RevId: 488669786
  • Loading branch information
tonihei authored and microkatz committed Nov 16, 2022
1 parent 1b24e6f commit 8438dac
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ public VideoSize getVideoSize() {

/** This method is not supported and returns {@link Size#UNKNOWN}. */
@Override
public Size getVideoSurfaceSize() {
public Size getSurfaceSize() {
return Size.UNKNOWN;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -762,10 +762,10 @@ public VideoSize getVideoSize() {
return player.getVideoSize();
}

/** Calls {@link Player#getVideoSurfaceSize()} on the delegate and returns the result. */
/** Calls {@link Player#getSurfaceSize()} on the delegate and returns the result. */
@Override
public Size getVideoSurfaceSize() {
return player.getVideoSurfaceSize();
public Size getSurfaceSize() {
return player.getSurfaceSize();
}

/** Calls {@link Player#clearVideoSurface()} on the delegate. */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2491,7 +2491,7 @@ default void onMetadata(Metadata metadata) {}
*
* @see Listener#onSurfaceSizeChanged(int, int)
*/
Size getVideoSurfaceSize();
Size getSurfaceSize();

/** Returns the current {@link CueGroup}. */
CueGroup getCurrentCues();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,7 @@ public final VideoSize getVideoSize() {
}

@Override
public final Size getVideoSurfaceSize() {
public final Size getSurfaceSize() {
// TODO: implement.
throw new IllegalStateException();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1220,7 +1220,7 @@ public VideoSize getVideoSize() {
}

@Override
public Size getVideoSurfaceSize() {
public Size getSurfaceSize() {
verifyApplicationThread();
return surfaceSize;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -519,9 +519,9 @@ public VideoSize getVideoSize() {
}

@Override
public Size getVideoSurfaceSize() {
public Size getSurfaceSize() {
blockUntilConstructorFinished();
return player.getVideoSurfaceSize();
return player.getSurfaceSize();
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ public VideoSize getVideoSize() {
}

@Override
public Size getVideoSurfaceSize() {
public Size getSurfaceSize() {
throw new UnsupportedOperationException();
}

Expand Down

0 comments on commit 8438dac

Please sign in to comment.