rem: var selectedIndex = gDownloadsView.selectedIndex;  
context: function onDownloadPause(aEvent){  var selectedIndex = gDownloadsView.selectedIndex;  var uri = aEvent.target.id;  gDownloadManager.pauseDownload(uri);  setRDFProperty(uri, "DownloadStatus", aEvent.target.getAttribute("status-internal"));  setRDFProperty(uri, "ProgressPercent", aEvent.target.getAttribute("progress"));  // now reset the richlistbox  gDownloadsView.clearSelection();  var rowCount = gDownloadsView.getRowCount();  if (selectedIndex >= rowCount)    gDownloadsView.selectedIndex = rowCount - 1;  else    gDownloadsView.selectedIndex = selectedIndex;  gDownloadsView.selectedItem.focus();}
meta: 8395	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/8395/61ae9e722d7e64483a483538da270520a97479f6/downloads.js/buggy/toolkit/mozapps/downloads/content/downloads.js