refactor  UIpicker logic