Android 2 keys at a time
<p>I am new to android development, making a simple game and using onKeyDown(.....) function but it works only for 1 key at a time, how to handle 2 keys at a time means can i move right or left with continous firing.</p>

<pre><code>@Override
public boolean onKeyDown(int keyCode, KeyEvent event) {
    // TODO Auto-generated method stub
    switch (keyCode){
    case KeyEvent.KEYCODE_DPAD_RIGHT:

        bottle_movx+=2;

    break;
    case KeyEvent.KEYCODE_DPAD_LEFT:

        bottle_movx-=2;
        break;

    case KeyEvent.KEYCODE_DPAD_DOWN:
        fire=bottle_movx;
        firechk=true;
        break;      

    }

    invalidate();
    return super.onKeyDown(keyCode, event);

}
</code></pre>
