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
6084a552
authored
Jan 14, 2021
by
olly
Committed by
Ian Baker
Jan 15, 2021
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Rename AnalyticsListener.onAudioSessionId for consistency
PiperOrigin-RevId: 351687086
parent
adb9dcb4
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
8 additions
and
8 deletions
RELEASENOTES.md
library/core/src/main/java/com/google/android/exoplayer2/analytics/AnalyticsCollector.java
library/core/src/main/java/com/google/android/exoplayer2/analytics/AnalyticsListener.java
library/core/src/main/java/com/google/android/exoplayer2/util/EventLogger.java
library/core/src/test/java/com/google/android/exoplayer2/analytics/AnalyticsCollectorTest.java
RELEASENOTES.md
View file @
6084a552
...
...
@@ -152,8 +152,8 @@
which can be immediately queried by calling
`SimpleExoPlayer.getAudioSessionId`
. The audio session ID will only
change if application code calls
`SimpleExoPlayer.setAudioSessionId`
.
*
`
AudioListener.onAudioSessionId`
is replaced with
`AudioListener
.onAudioSessionIdChanged
`
. Note that
*
`
onAudioSessionId`
is replaced with
`onAudioSessionIdChanged`
in
`AudioListener
`
and
`AnalyticsListener
`
. Note that
`onAudioSessionIdChanged`
is called in fewer cases than
`onAudioSessionId`
was called, due to the improved handling of audio
session IDs as described above.
...
...
library/core/src/main/java/com/google/android/exoplayer2/analytics/AnalyticsCollector.java
View file @
6084a552
...
...
@@ -305,7 +305,7 @@ public class AnalyticsCollector
sendEvent
(
eventTime
,
AnalyticsListener
.
EVENT_AUDIO_SESSION_ID
,
listener
->
listener
.
onAudioSessionId
(
eventTime
,
audioSessionId
));
listener
->
listener
.
onAudioSessionId
Changed
(
eventTime
,
audioSessionId
));
}
@Override
...
...
library/core/src/main/java/com/google/android/exoplayer2/analytics/AnalyticsListener.java
View file @
6084a552
...
...
@@ -805,12 +805,12 @@ public interface AnalyticsListener {
default
void
onAudioDisabled
(
EventTime
eventTime
,
DecoderCounters
counters
)
{}
/**
* Called when the audio session
id is set
.
* Called when the audio session
ID changes
.
*
* @param eventTime The event time.
* @param audioSessionId The audio session
id
.
* @param audioSessionId The audio session
ID
.
*/
default
void
onAudioSessionId
(
EventTime
eventTime
,
int
audioSessionId
)
{}
default
void
onAudioSessionId
Changed
(
EventTime
eventTime
,
int
audioSessionId
)
{}
/**
* Called when the audio attributes change.
...
...
library/core/src/main/java/com/google/android/exoplayer2/util/EventLogger.java
View file @
6084a552
...
...
@@ -353,7 +353,7 @@ public class EventLogger implements AnalyticsListener {
}
@Override
public
void
onAudioSessionId
(
EventTime
eventTime
,
int
audioSessionId
)
{
public
void
onAudioSessionId
Changed
(
EventTime
eventTime
,
int
audioSessionId
)
{
logd
(
eventTime
,
"audioSessionId"
,
Integer
.
toString
(
audioSessionId
));
}
...
...
library/core/src/test/java/com/google/android/exoplayer2/analytics/AnalyticsCollectorTest.java
View file @
6084a552
...
...
@@ -2199,7 +2199,7 @@ public final class AnalyticsCollectorTest {
}
@Override
public
void
onAudioSessionId
(
EventTime
eventTime
,
int
audioSessionId
)
{
public
void
onAudioSessionId
Changed
(
EventTime
eventTime
,
int
audioSessionId
)
{
reportedEvents
.
add
(
new
ReportedEvent
(
EVENT_AUDIO_SESSION_ID
,
eventTime
));
}
...
...
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