반응형
[android] earphone(headset) plug or unplug intent action |
https://developer.android.com/reference/android/media/AudioManager.html#ACTION_HEADSET_PLUG
-
Action 은 AudioMangaer.ACTION_HEADSET_PLUG.
intent extra 로 아래 값들이 있다.
"state"
0 : unplugged
1 : plugged
"name"
headset type, human readable string
"microphone"
0 : microphone 기능이 없음
1 : microphone 기능이 함께 있음
-
manifest 를 통해서 receiver 등록되지 않는다.
앱에서 명시적으로 등록해야 한다.
반응형
'프로그래밍 놀이터 > 안드로이드, Java' 카테고리의 다른 글
[android] Google Sign In 준비하기 #1 (2) | 2018.02.22 |
---|---|
[android] odex 에 대해 알아보자. (0) | 2018.01.24 |
[android] Build 할 때 MissingTranslation 관련 에러가 난다면.. (0) | 2018.01.21 |
[Java] Jit Compiler 에 대한 이야기 (0) | 2018.01.14 |
[android] Firebase JobDispatcher 문제.. (Job 미실행) (0) | 2017.12.05 |
댓글