rem: fp.displayDirectory = dir; 
context: function selectFileToOpen(label, prefRoot){  var fileURL = null;  // Get filepicker component.  const nsIFilePicker = Components.interfaces.nsIFilePicker;  var fp = Components.classes["@mozilla.org/filepicker;1"].createInstance(nsIFilePicker);  fp.init(window, gNavigatorBundle.getString(label), nsIFilePicker.modeOpen);  fp.appendFilters(nsIFilePicker.filterAll | nsIFilePicker.filterText | nsIFilePicker.filterImages |                   nsIFilePicker.filterXML | nsIFilePicker.filterHTML);  const filterIndexPref = prefRoot + "filterIndex";  const lastDirPref = prefRoot + "dir";  // use a pref to remember the filterIndex selected by the user.  var index = 0;  try {    index = pref.getIntPref(filterIndexPref);  } catch (ex) {  }  fp.filterIndex = index;  // use a pref to remember the displayDirectory selected by the user.  var dir = null;  try {    dir = pref.getComplexValue(lastDirPref, Components.interfaces.nsILocalFile);  } catch (ex) {  }  fp.displayDirectory = dir;  if (fp.show() == nsIFilePicker.returnOK) {    pref.setIntPref(filterIndexPref, fp.filterIndex);    pref.setComplexValue(lastDirPref,                         Components.interfaces.nsILocalFile,                         fp.file.parent.QueryInterface(Components.interfaces.nsILocalFile));    fileURL = fp.fileURL;  }  return fileURL;}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/d7003975e2b348d024f3e1b5b185a4f6181a26c1/navigator.js/clean/suite/browser/navigator.js