Resolve #423

Pretty self-explanatory. A flags enum is now used instead of a pair of
booleans.

The only caveat here is that the function takes an int type, due to a
stupid bug in C++ that says that (enum_val_a | enum_val_b) is of type
int and may not implicitly cast back to type enum.