Hi all!
I've implemented onKeyListener for my app, and almost everything si OK, but the only one red hangup button doesn't work. When I press this one device locks the screen. Can somebody tell me, how to deal with this?
raj_J2ME wrote:Are you getting the key code and the key event for this key inside your app ?
raj_J2ME wrote:Are you testing the app on the emulator or read device?
@Override
public boolean dispatchKeyEvent(KeyEvent event) {
int keyCode = event.getKeyCode();
if (event.getAction() == KeyEvent.ACTION_DOWN) {
if (keyCode == KeyEvent.KEYCODE_ENDCALL) {
fireEvent();
return true;
} else {
return super.dispatchKeyEvent(event);
}
}
}
03-31 20:04:08.152: DEBUG/WindowManager(59): I'm tired mEndcallBehavior=0x2
Since the 1.5+ API the ability to programmatically detect
KeyEvent.KEYCODE_ENDCALL has been removed from the API, so it is impossible
to detect when the ENDCALL button is pressed. [...]
Return to SDK/ADT/Emulator Problems
Users browsing this forum: No registered users and 3 guests