Home
last modified time | relevance | path

Searched refs:AudioFocus (Results 1 – 2 of 2) sorted by relevance

/development/samples/RandomMusicPlayer/src/com/example/android/musicplayer/
DMusicService.java113 enum AudioFocus { enum in MusicService
118 AudioFocus mAudioFocus = AudioFocus.NoFocusNoDuck;
199 mAudioFocus = AudioFocus.Focused; // no focus feature, so we always "have" audio focus in onCreate()
345 if (mAudioFocus == AudioFocus.Focused && mAudioFocusHelper != null in giveUpAudioFocus()
347 mAudioFocus = AudioFocus.NoFocusNoDuck; in giveUpAudioFocus()
359 if (mAudioFocus == AudioFocus.NoFocusNoDuck) { in configAndStartMediaPlayer()
366 else if (mAudioFocus == AudioFocus.NoFocusCanDuck) in configAndStartMediaPlayer()
391 if (mAudioFocus != AudioFocus.Focused && mAudioFocusHelper != null in tryToGetAudioFocus()
393 mAudioFocus = AudioFocus.Focused; in tryToGetAudioFocus()
558 mAudioFocus = AudioFocus.Focused; in onGainedAudioFocus()
[all …]
/development/samples/browseable/MediaBrowserService/src/com.example.android.mediabrowserservice/
DMusicService.java154 enum AudioFocus { enum in MusicService
162 private AudioFocus mAudioFocus = AudioFocus.NoFocusNoDuck;
575 mAudioFocus = AudioFocus.Focused; in onAudioFocusChange()
583 mAudioFocus = canDuck ? AudioFocus.NoFocusCanDuck : AudioFocus.NoFocusNoDuck; in onAudioFocusChange()
716 if (mAudioFocus == AudioFocus.NoFocusNoDuck) { in configMediaPlayerState()
722 if (mAudioFocus == AudioFocus.NoFocusCanDuck) { in configMediaPlayerState()
927 if (mAudioFocus != AudioFocus.Focused) { in tryToGetAudioFocus()
931 mAudioFocus = AudioFocus.Focused; in tryToGetAudioFocus()
941 if (mAudioFocus == AudioFocus.Focused) { in giveUpAudioFocus()
943 mAudioFocus = AudioFocus.NoFocusNoDuck; in giveUpAudioFocus()