hasFlag static method

bool hasFlag(
  1. int leftFlags,
  2. int rightFlags
)

Returns true if leftFlags has at least one member in rightFlags (intersection) for example leftFlags= MultiFingerGesture.pinchMove | MultiFingerGesture.rotate and rightFlags= MultiFingerGesture.rotate returns true because both have MultiFingerGesture.rotate flag

Implementation

static bool hasFlag(int leftFlags, int rightFlags) {
  return leftFlags & rightFlags != 0;
}