This if performs a bitwise "and" of the value of button and 1 and then compares the result to 0. In essense the bitwise and will be 1 if and only if the last(least significant) bit of button is one which is also equivalent to button being odd.
So in short this if checks if button is odd.