Run tests on Travis-CI.
[dygraphs.git] / gallery / stock.js
index 511aef1..ad7319e 100644 (file)
@@ -1,3 +1,5 @@
+/*global Gallery,Dygraph,data */
+/*global stockData */
 Gallery.register(
   'stock',
   {
@@ -20,12 +22,12 @@ Gallery.register(
 
       var linear = document.getElementById("linear");
       var log = document.getElementById("log");
-      linear.onclick = function() { setLog(false); };
-      log.onclick = function() { setLog(true); };
       var setLog = function(val) {
         g.updateOptions({ logscale: val });
         linear.disabled = !val;
         log.disabled = val;
       };
+      linear.onclick = function() { setLog(false); };
+      log.onclick = function() { setLog(true); };
     }
   });