Rated 5 out of 5 stars

often it is desirable to select on delete when using the button, to rapidly delete multiple messages. but most definitely not when using the contextmenu. so i use this method in userChromeJS. it avoids a permanent listener; the ultimate extension would provide a pref for both contextmenu and button behavior.
FolderDisplayWidget.prototype._noSelectAfterDelete = false;
FolderDisplayWidget.prototype.hintAboutToDeleteMessages =
function FolderDisplayWidget_hintAboutToDeleteMessages() {
this._nextViewIndexAfterDelete =
this._noSelectAfterDelete ? -1 : this.view.dbView.msgToSelectAfterDelete;

var mcD = document.getElementById("mailContext-delete");
if (mcD)
mcD.setAttribute("onclick", "setSelectAfterDeleteBehavior('contextmenu')");
var bmD = document.getElementById("button-mark-deleted");
if (bmD)
bmD.setAttribute("onclick", "setSelectAfterDeleteBehavior('button')");

function setSelectAfterDeleteBehavior(aWho) {
gFolderDisplay._noSelectAfterDelete = aWho == "contextmenu" ? true : false;

This review is for a previous version of the add-on (1.0b2).