mirror of
https://github.com/samsonjs/media.git
synced 2026-04-04 11:05:47 +00:00
Check if controller is used when performing click directly.
Issue:#6260 PiperOrigin-RevId: 261647858
This commit is contained in:
parent
d6e74bc19b
commit
790deb71db
2 changed files with 6 additions and 3 deletions
|
|
@ -27,6 +27,9 @@
|
|||
over other selection parameters.
|
||||
* Remove `AnalyticsCollector.Factory`. Instances can be created directly and
|
||||
the `Player` set later using `AnalyticsCollector.setPlayer`.
|
||||
* Fix issue when calling `performClick` on `PlayerView` without
|
||||
`PlayerControlView`
|
||||
([#6260](https://github.com/google/ExoPlayer/issues/6260)).
|
||||
|
||||
### 2.10.4 ###
|
||||
|
||||
|
|
|
|||
|
|
@ -1156,6 +1156,9 @@ public class PlayerView extends FrameLayout implements AdsLoader.AdViewProvider
|
|||
// Internal methods.
|
||||
|
||||
private boolean toggleControllerVisibility() {
|
||||
if (!useController || player == null) {
|
||||
return false;
|
||||
}
|
||||
if (!controller.isVisible()) {
|
||||
maybeShowController(true);
|
||||
} else if (controllerHideOnTouch) {
|
||||
|
|
@ -1491,9 +1494,6 @@ public class PlayerView extends FrameLayout implements AdsLoader.AdViewProvider
|
|||
|
||||
@Override
|
||||
public boolean onSingleTapUp(MotionEvent e) {
|
||||
if (!useController || player == null) {
|
||||
return false;
|
||||
}
|
||||
return toggleControllerVisibility();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue