Heres what I would suggest- First, Move the white keys off screen before checking for the black ones. Next, move them back to their original spot. Finally, if none of the black keys ones were pressed, check for the white keys.