Changed button encodeType method to match new pattern
regen after making small formatting changes