Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: new-options.js

Issue 29373674: Issue 3487 - Add links to the help tab (Closed)
Patch Set: Fixed nit Created March 3, 2017, 10:20 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « new-options.html ('k') | skin/new-options.css » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: new-options.js
===================================================================
--- a/new-options.js
+++ b/new-options.js
@@ -825,6 +825,57 @@
}, false);
var customFilterEditButtons = document.querySelectorAll("#custom-filters-edit-wrapper button");
+ // Help tab
+ getDocLink("faq", function(link)
+ {
+ E("link-faq").setAttribute("href", link);
+ });
+ getDocLink("social_twitter", function(link)
+ {
+ E("link-twitter").setAttribute("href", link);
+ });
+ getDocLink("social_facebook", function(link)
+ {
+ E("link-facebook").setAttribute("href", link);
+ });
+ getDocLink("social_gplus", function(link)
+ {
+ E("link-gplus").setAttribute("href", link);
+ });
+ getDocLink("social_renren", function(link)
+ {
+ E("link-renren").setAttribute("href", link);
+ });
+ getDocLink("social_weibo", function(link)
+ {
+ E("link-weibo").setAttribute("href", link);
+ });
+
+ // Set forum link
+ ext.backgroundPage.sendMessage(
+ {
+ type: "app.get",
+ what: "platform"
+ },
+ function(platform)
+ {
+ ext.backgroundPage.sendMessage(
+ {
+ type: "app.get",
+ what: "application"
+ },
+ function(application)
+ {
+ if (platform == "chromium" && application != "opera")
+ application = "chrome";
+
+ getDocLink(application + "_support", function(link)
+ {
+ E("link-forum").setAttribute("href", link);
+ });
+ });
+ });
+
E("dialog").addEventListener("keydown", function(e)
{
switch (getKey(e))
« no previous file with comments | « new-options.html ('k') | skin/new-options.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld