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
(cherry picked from commit 8438dac)
  • Loading branch information
tonihei authored and microkatz committed Nov 17, 2022
1 parent db2ab52 commit 6108c05
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
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
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
Expand Up @@ -2477,7 +2477,7 @@ default void onMetadata(Metadata metadata) {}
*
* @see Listener#onSurfaceSizeChanged(int, int)
*/
Size getVideoSurfaceSize();
Size getSurfaceSize();

/** Returns the current {@link CueGroup}. */
CueGroup getCurrentCues();
Expand Down
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
Expand Up @@ -1220,7 +1220,7 @@ public VideoSize getVideoSize() {
}

@Override
public Size getVideoSurfaceSize() {
public Size getSurfaceSize() {
verifyApplicationThread();
return surfaceSize;
}
Expand Down
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
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 6108c05

Please sign in to comment.