+ result_timer: result_timer,
+ set_item: set_item,
+ reset: make_defined_state,
+ init_results: function () {
+ $('div.part_picker_part').each(function(){
+ $(this).click(function(){
+ set_item({
+ id: $(this).children('input.part_picker_id').val(),
+ name: $(this).children('input.part_picker_description').val(),
+ unit: $(this).children('input.part_picker_unit').val(),
+ });
+ close_popup();
+ $dummy.focus();
+ return true;
+ });
+ });
+ $('#part_selection').keydown(function(e){
+ if (e.which == KEY.ESCAPE) {
+ close_popup();
+ $dummy.focus();
+ }
+ });
+ }