Skip to content

Commit

Permalink
Add braces
Browse files Browse the repository at this point in the history
  • Loading branch information
Hydr8gon committed Apr 22, 2014
1 parent c81ac09 commit 4edb0a3
Showing 1 changed file with 4 additions and 0 deletions.
Expand Up @@ -122,12 +122,16 @@ public boolean onTouch(View v, MotionEvent event)
for (InputOverlayDrawableButton button : overlayButtons)
{
if (button.getBounds().contains((int)event.getX(), (int)event.getY()))
{
NativeLibrary.onTouchEvent(0, button.getId(), buttonState);
}
else
{
// Because the above code only changes the state for the button that is being touched, sliding off the
// button does not allow for it to be released. Release the button as soon as the touch coordinates leave
// the button bounds.
NativeLibrary.onTouchEvent(0, button.getId(), ButtonState.RELEASED);
}
}


Expand Down

0 comments on commit 4edb0a3

Please sign in to comment.