Horizontal Gene Transfer and Plastid Endosymbiosis in Dinoflagellate Gene Innovation