ankidroid/Anki-Android — pull request #241 by tanzoniteblack (2014-03-31 15:53:58+00:00)
Title: Duck background audio

Use AudioManager's audio focus to grant transient audio focus from other apps.
Not all media players respect audio focus, but with a well behaved media
player like Google Play Music, this will lower the volume during
playback of audio from AnkiDroid, and then return the volume to regular
level after it's finished. This is identical to what Google Maps uses to
bring focus to driving directions while playing music from another app.