rem: var tree = GetThreadTree(); var selection = tree.selectedItems; if(selection.length > 0) return selection[0]; else 
add: var threadTree = GetThreadTree(); var selectedMessages = threadTree.selectedItems; var numMessages = selectedMessages.length; if(index <0 || index > (numMessages - 1)) 
context: function GetSelectedMessage(){	var tree = GetThreadTree();	var selection = tree.selectedItems;	if(selection.length > 0)		return selection[0];	else		return null;}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/0938bbb70031b70863a26099bd6eab59d9a14e34/msgMail3PaneWindow.js/buggy/mailnews/base/resources/content/msgMail3PaneWindow.js