Add isHorizontal in DirectionUtils