Bug 1081296 - Add sumo link for promotional translation doorhanger. r=florian

This commit is contained in:
Felipe Gomes 2014-10-10 17:37:51 -03:00
parent 1d871dfa7e
commit e9467f9c8d

View File

@ -31,7 +31,8 @@
anonid="welcomeHeadline"/>
<xul:description class="translation-welcome-body" anonid="welcomeBody"/>
<xul:hbox align="center">
<xul:label anonid="learnMore" class="plain text-link"/>
<xul:label anonid="learnMore" class="plain text-link"
onclick="openUILinkIn('https://support.mozilla.org/en-US/products/firefox/automatic-translation', 'tab'); this.parentNode.parentNode.parentNode.hidePopup();"/>
<xul:spacer flex="1"/>
<xul:button class="translate-infobar-element" anonid="thanksButton"
onclick="this.parentNode.parentNode.parentNode.hidePopup();"/>
@ -215,7 +216,8 @@
this.state = aTranslation.state;
const kWelcomePref = "browser.translation.ui.welcomeMessageShown";
if (Services.prefs.prefHasUserValue(kWelcomePref))
if (Services.prefs.prefHasUserValue(kWelcomePref) ||
this.translation.browser != gBrowser.selectedBrowser)
return;
this.addEventListener("transitionend", function onShown() {