Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
SDK
/
exoplayer
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
3a0b1f7d
authored
Dec 11, 2020
by
olly
Committed by
Ian Baker
Jan 11, 2021
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Fix UI menu not dismissing on API level 22 and earlier
Issue: #8272 PiperOrigin-RevId: 347010412
parent
a028ce89
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
0 deletions
RELEASENOTES.md
library/ui/src/main/java/com/google/android/exoplayer2/ui/StyledPlayerControlView.java
RELEASENOTES.md
View file @
3a0b1f7d
...
@@ -2,6 +2,11 @@
...
@@ -2,6 +2,11 @@
### 2.12.3 (???-??-??) ###
### 2.12.3 (???-??-??) ###
*
UI:
*
Fix issue where pop-up menus belonging to
`StyledPlayerControlView`
would not be dismissed when tapping outside of the menu area or pressing
the back button, on API level 22 and earlier
(
[
#8272
](
https://github.com/google/ExoPlayer/issues/8272
)
).
*
IMA extension:
*
IMA extension:
*
Fix a condition where playback can get stuck before an empty ad
*
Fix a condition where playback can get stuck before an empty ad
(
[
#8205
](
https://github.com/google/ExoPlayer/issues/8205
)
).
(
[
#8205
](
https://github.com/google/ExoPlayer/issues/8205
)
).
...
...
library/ui/src/main/java/com/google/android/exoplayer2/ui/StyledPlayerControlView.java
View file @
3a0b1f7d
...
@@ -21,7 +21,9 @@ import android.annotation.SuppressLint;
...
@@ -21,7 +21,9 @@ import android.annotation.SuppressLint;
import
android.content.Context
;
import
android.content.Context
;
import
android.content.res.Resources
;
import
android.content.res.Resources
;
import
android.content.res.TypedArray
;
import
android.content.res.TypedArray
;
import
android.graphics.Color
;
import
android.graphics.Typeface
;
import
android.graphics.Typeface
;
import
android.graphics.drawable.ColorDrawable
;
import
android.graphics.drawable.Drawable
;
import
android.graphics.drawable.Drawable
;
import
android.os.Looper
;
import
android.os.Looper
;
import
android.util.AttributeSet
;
import
android.util.AttributeSet
;
...
@@ -673,6 +675,11 @@ public class StyledPlayerControlView extends FrameLayout {
...
@@ -673,6 +675,11 @@ public class StyledPlayerControlView extends FrameLayout {
settingsView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
()));
settingsView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
()));
settingsWindow
=
settingsWindow
=
new
PopupWindow
(
settingsView
,
LayoutParams
.
WRAP_CONTENT
,
LayoutParams
.
WRAP_CONTENT
,
true
);
new
PopupWindow
(
settingsView
,
LayoutParams
.
WRAP_CONTENT
,
LayoutParams
.
WRAP_CONTENT
,
true
);
if
(
Util
.
SDK_INT
<
23
)
{
// Work around issue where tapping outside of the menu area or pressing the back button
// doesn't dismiss the menu as expected. See: https://github.com/google/ExoPlayer/issues/8272.
settingsWindow
.
setBackgroundDrawable
(
new
ColorDrawable
(
Color
.
TRANSPARENT
));
}
settingsWindow
.
setOnDismissListener
(
componentListener
);
settingsWindow
.
setOnDismissListener
(
componentListener
);
needToHideBars
=
true
;
needToHideBars
=
true
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment