Anonymous avatar Anonymous committed edbec50

Fixes issue #290 where variables were in the global scope.

Comments (0)

Files changed (6)

src/jqplot.axisTickRenderer.js

         if (this.prefix && !this.formatString) {
             this.label = this.prefix + this.label;
         }
-        style ='style="position:absolute;';
+        var style ='style="position:absolute;';
         if (Number(this.label)) {
             style +='white-space:nowrap;';
         }

src/jqplot.canvasGridRenderer.js

             ctx.lineCap = 'butt';
             ctx.lineWidth = this.gridLineWidth;
             ctx.strokeStyle = this.gridLineColor;
-            var b, e;
+            var b, e, s, m;
             var ax = ['xaxis', 'yaxis', 'x2axis', 'y2axis'];
             for (var i=4; i>0; i--) {
                 var name = ax[i-1];

src/jqplot.tableLegendRenderer.js

             this._elem = $('<table class="jqplot-table-legend" style="'+ss+'"></table>');
         
             var pad = false, 
-                reverse = false;
+                reverse = false,
+				s;
             for (var i = 0; i< series.length; i++) {
                 s = series[i];
                 if (s._stack || s.renderer.constructor == $.jqplot.BezierCurveRenderer){

src/jqplot.themeEngine.js

     $.jqplot.ThemeEngine.prototype.init = function() {
         // get the Default theme from the current plot settings.
         var th = new $.jqplot.Theme({_name:'Default'});
-        var n, i;
+        var n, i, nn;
         
         for (n in th.target) {
             if (n == "textColor") {
         
         var i = 0;
         var length = jsDate.matchers.length;
-        var pattern;
-        var current = parsable;
+        var pattern,
+			ms,
+			current = parsable;
         while (i < length) {
             ms = Date.parse(current);
             if (!isNaN(ms)) {

src/plugins/jqplot.canvasTextRenderer.js

     // returns float
     $.jqplot.CanvasTextRenderer.prototype.normalizeFontSize = function(sz) {
         sz = String(sz);
-        n = parseFloat(sz);
+        var n = parseFloat(sz);
         if (sz.indexOf('px') > -1) {
             return n/this.pt2px;
         }
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.