| Index: mobile/android/chrome/content/aboutAdblockBrowser.xhtml |
| =================================================================== |
| --- a/mobile/android/chrome/content/aboutAdblockBrowser.xhtml |
| +++ b/mobile/android/chrome/content/aboutAdblockBrowser.xhtml |
| @@ -49,19 +49,19 @@ |
| #endif |
| </p> |
| </div> |
| </div> |
| <ul id="aboutLinks"> |
| <div class="top-border"></div> |
| - <li><a href="https://adblockplus.org/en/faq">&aboutPage.faq.label;</a></li> |
| - <li><a href="https://adblockplus.org/en/privacy">&aboutPage.privacyPolicy.label;</a></li> |
| - <li><a href="https://adblockplus.org/en/contributors">&aboutPage.credits.label;</a></li> |
| + <li><a id="faqURL">&aboutPage.faq.label;</a></li> |
| + <li><a id="privacyURL">&aboutPage.privacyPolicy.label;</a></li> |
| + <li><a id="creditsURL">&aboutPage.credits.label;</a></li> |
| <div class="bottom-border"></div> |
| </ul> |
| <div id="aboutDetails"> |
| <p>&logoTrademark;</p> |
| </div> |
| <script type="application/javascript;version=1.8"><![CDATA[ |
| @@ -100,16 +100,34 @@ |
| let distroField = document.getElementById("distributionAbout"); |
| distroField.textContent = distroAbout; |
| distroField.hidden = false; |
| } |
| } catch (e) { |
| // Pref is unset |
| } |
| + // Using formatted URLs. See https://issues.adblockplus.org/ticket/3220 |
| + // get URLs from prefs |
| + try { |
|
Felix Dahlke
2016/09/15 14:59:22
Something seems wrong here with the indentation.
diegocarloslima
2016/10/21 13:37:43
Acknowledged.
|
| + let formatter = Cc["@mozilla.org/toolkit/URLFormatterService;1"].getService(Ci.nsIURLFormatter); |
| + |
| + let links = [ |
| + {id: "faqURL", pref: "app.faqURL"}, |
|
Felix Dahlke
2016/09/15 14:59:22
Given that we copied this code from about.js, we c
diegocarloslima
2016/10/21 13:37:43
Acknowledged.
|
| + {id: "privacyURL", pref: "app.privacyURL"}, |
| + {id: "creditsURL", pref: "app.creditsURL"}, |
| + ]; |
| + |
| + links.forEach(function(link) { |
| + let url = formatter.formatURLPref(link.pref); |
| + let element = document.getElementById(link.id); |
| + element.setAttribute("href", url); |
| + }); |
| + } catch (ex) {} |
| + |
| #ifdef MOZ_UPDATER |
| let Updater = { |
| update: null, |
| init: function() { |
| Services.obs.addObserver(this, "Update:CheckResult", false); |
| }, |