Applications don't get to receive ENDCALL. Also I believe the built-in handling of it is at a lower level in the input queue than injectKeyEvent(), so using that API will not execute it.
--
Dianne Hackborn
Android framework engineer
hac...@android.comNote: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them.