rem:  for (var i = 0; i < select[0].childNodes[0].childNodes.length; i ++) if (select[0].childNodes[0].childNodes[i].getAttribute("data") == popupValue) { select[0].selectedItem = select[0].childNodes[0].childNodes[i]; break; } 
add: select[0].selectedItem = select[0].childNodes[0].childNodes[awGetSelectItemIndex(popupValue)]; 
context: function _awSetInputAndPopup(inputValue, popupValue, parentNode, templateNode){	// remove leading spaces	while (inputValue[0] == " " )		inputValue = inputValue.substring(1, inputValue.length);	    top.MAX_RECIPIENTS++;    var newNode = templateNode.cloneNode(true);    parentNode.appendChild(newNode); // we need to insert the new node before we set the value of the select element!    var input = newNode.getElementsByTagName(awInputElementName());    if ( input && input.length == 1 )    {	    input[0].setAttribute("value", inputValue);	    input[0].setAttribute("id", "msgRecipient#" + top.MAX_RECIPIENTS);	}    var select = newNode.getElementsByTagName(awSelectElementName());    if ( select && select.length == 1 )    {//Doesn't work!	    select[0].setAttribute("value", popupValue);        for (var i = 0; i < select[0].childNodes[0].childNodes.length; i ++)            if (select[0].childNodes[0].childNodes[i].getAttribute("data") == popupValue)            {                select[0].selectedItem = select[0].childNodes[0].childNodes[i];                break;            }	    select[0].setAttribute("id", "msgRecipientType#" + top.MAX_RECIPIENTS);	}}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/879640409e350f33f86e9de6807dafc030a65486/addressingWidgetOverlay.js/clean/mailnews/compose/resources/content/addressingWidgetOverlay.js