A Wigan man who threw a brick at a police officer during violent disorder in Southport has been jailed.