refs #6500. Check valid colour before setting.

Check that a valid colour has been chosen before setting anything. If cancel is clicked, the colour fetched will not be valid.
Merge remote-tracking branch 'origin/feature/6500_colour_change_defect'