1
0
mirror of https://github.com/MailHops/mailhops-plugin.git synced 2025-05-17 06:40:08 -07:00

Added CompactHeaders header check to hide MailHops bar

This commit is contained in:
Andrew Van Tassel 2017-01-12 22:45:19 -07:00
parent 10d71d1736
commit b55542877b
2 changed files with 20 additions and 1 deletions

View File

@ -134,6 +134,18 @@ mailHops.StreamListener =
* loop through the header, find out if we have received-from headers
*/
mailHops.loadHeaderData = function() {
// CompactHeader toggle header logic
var compactHeadersView = document.getElementById('CompactHeader_collapsedHeaderView');
if(!!compactHeadersView){
if(compactHeadersView.collapsed===true){
mailHopsDisplay.toggleMailHopsBar(true);
} else if(compactHeadersView.collapsed===false){
mailHopsDisplay.toggleMailHopsBar(false);
return;
}
}
var msgURI = null ;
if ( gDBView ){

View File

@ -369,5 +369,12 @@ var mailHopsDisplay =
this.resultText.setAttribute('value', displayText+' ( '+distanceText+' )');
this.resultText.style.backgroundImage = 'url('+image+')';
}//end route
}, //end route
toggleMailHopsBar: function(show){
if(show && this.mhBox.style.display=='none')
this.mhBox.style.display='';
else if(!show && this.mhBox.style.display=='')
this.mhBox.style.display='none';
}
};