rem: if (filterAction.type == nsMsgFilterAction.MoveToFolder) {  gMoveToFolderCheckbox.checked = true; var target = filterAction.targetFolderUri; if (target) SetFolderPicker(target, gActionTargetMoveElement.id); } else if (filterAction.type == nsMsgFilterAction.CopyToFolder) {  gCopyToFolderCheckbox.checked = true; var target = filterAction.targetFolderUri; if (target) SetFolderPicker(target, gActionTargetCopyElement.id); } else if (filterAction.type == nsMsgFilterAction.ChangePriority) { gChangePriorityCheckbox.checked = true;  var selectedPriority = gActionPriority.getElementsByAttribute("value", filterAction.priority).item(0); 
add: var newActionRow = document.createElement('listitem'); newActionRow.setAttribute('initialActionIndex', actionIndex); newActionRow.className = 'ruleaction'; gFilterActionList.appendChild(newActionRow); newActionRow.setAttribute('value', gFilterActionStrings[filterAction.type]); } 
context: function initializeDialog(filter){    gFilterNameElement.value = filter.filterName;    var actionList = filter.actionList;    var numActions = actionList.Count();        for (var actionIndex=0; actionIndex < numActions; actionIndex++)    {      var filterAction = actionList.QueryElementAt(actionIndex, Components.interfaces.nsIMsgRuleAction);      if (filterAction.type == nsMsgFilterAction.MoveToFolder)       {        // preselect target folder        gMoveToFolderCheckbox.checked = true;        var target = filterAction.targetFolderUri;        if (target)           SetFolderPicker(target, gActionTargetMoveElement.id);      }      else if (filterAction.type == nsMsgFilterAction.CopyToFolder)      {        // preselect target folder        gCopyToFolderCheckbox.checked = true;        var target = filterAction.targetFolderUri;        if (target)           SetFolderPicker(target, gActionTargetCopyElement.id);      }      else if (filterAction.type == nsMsgFilterAction.ChangePriority)       {        gChangePriorityCheckbox.checked = true;        // initialize priority        var selectedPriority = gActionPriority.getElementsByAttribute("value", filterAction.priority).item(0);        if (selectedPriority)           gActionPriority.selectedItem = selectedPriority;      }      else if (filterAction.type == nsMsgFilterAction.Label)       {        gLabelCheckbox.checked = true;        // initialize label        var selectedLabel = gActionLabel.getElementsByAttribute("value", filterAction.label).item(0);        if (selectedLabel)           gActionLabel.selectedItem = selectedLabel;      }      else if (filterAction.type == nsMsgFilterAction.JunkScore)       {        gJunkScoreCheckbox.checked = true;        // initialize junk score        var selectedJunkScore = gActionJunkScore.getElementsByAttribute("value", filterAction.junkScore).item(0);        if (selectedJunkScore)           gActionJunkScore.selectedItem = selectedJunkScore;      }      else if (filterAction.type == nsMsgFilterAction.Forward)      {        gForwardToCheckbox.checked = true;        gActionForwardTo.value = filterAction.strValue;       }      else if (filterAction.type == nsMsgFilterAction.Reply)      {        gReplyWithTemplateCheckbox.checked = true;        gReplyWithTemplateUri = filterAction.strValue;       }      else if (filterAction.type == nsMsgFilterAction.MarkRead)        gMarkReadCheckbox.checked = true;      else if (filterAction.type == nsMsgFilterAction.MarkFlagged)        gMarkFlaggedCheckbox.checked = true;      else if (filterAction.type == nsMsgFilterAction.Delete)        gDeleteCheckbox.checked = true;      else if (filterAction.type == nsMsgFilterAction.WatchThread)        gWatchCheckbox.checked = true;      else if (filterAction.type == nsMsgFilterAction.KillThread)        gKillCheckbox.checked = true;      else if (filterAction.type == nsMsgFilterAction.DeleteFromPop3Server)        gDeleteFromServerCheckbox.checked = true;      else if (filterAction.type == nsMsgFilterAction.FetchBodyFromPop3Server)        gFetchBodyFromServerCheckbox.checked = true;      SetUpFilterActionList(getScope(filter));    }    var scope = getScope(filter);    setSearchScope(scope);    initializeSearchRows(scope, filter.searchTerms);}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/4a95f3d489151db27fe9745922f9dd0ca4177049/FilterEditor.js/clean/mailnews/base/search/resources/content/FilterEditor.js