What is the PhoneStateListener state when outgoing call is answered?

安稳与你 提交于 2020-01-02 09:24:48

问题


I want to know when an outgoing call is answered in my app. I am using a method called onCallStateChanged() from the PhoneStateListener class. I am looking at the Logcat when the outgoing call is answered to see which state it goes into (IDLE, OFFHOOK or Ringing). As per the documentation I would think it would go into the OFFHOOK but that is not the case.
Any ideas on how I can detect the outgoing call being answered?


回答1:


Phone state is Phonestate.Offhook as you are answering the call by offhooking the phone, it's obvious.



来源:https://stackoverflow.com/questions/9756815/what-is-the-phonestatelistener-state-when-outgoing-call-is-answered

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!