Fixed tutorial links, especially to external pages
diff --git a/dev/js/src/tutorial.js b/dev/js/src/tutorial.js
index a028b8e..55c2415 100644
--- a/dev/js/src/tutorial.js
+++ b/dev/js/src/tutorial.js
@@ -78,7 +78,6 @@
this.hide();
},
-
/**
* Decorate a page with query event handler.
*/
@@ -92,6 +91,20 @@
};
},
+ /**
+ * Decorate a page with documentation links
+ */
+ initDocLinks : function (d) {
+ var dl = d.getElementsByClassName('doc-link');
+ var that = this;
+ for (var i = 0; i < dl.length; i++) {
+ dl[i].onclick = function (e) {
+ that.setPage(this.getAttribute('href'));
+ return true;
+ };
+ };
+ },
+
/**
* Show the tutorial page embedded.