Skip to content

Commit ef7ed52

Browse files
hansonrhansonr
authored andcommitted
aesthetic fix for var i
1 parent fccec29 commit ef7ed52

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

sources/net.sf.j2s.java.core/src/swingjs/jquery/jquery-ui-j2sslider.js

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,11 @@
5757
},
5858

5959
_create : function() {
60-
var i, handleCount, o = this.options, existingHandles = this.element
61-
.find(".ui-j2sslider-handle")
62-
.addClass(
63-
"ui-state-default ui-corner-all"), handle = "<a class='ui-j2sslider-handle ui-state-default ui-corner-all' href='#'></a>", handles = [];
60+
var handleCount,
61+
o = this.options,
62+
existingHandles = this.element.find(".ui-j2sslider-handle").addClass("ui-state-default ui-corner-all"),
63+
handle = "<a class='ui-j2sslider-handle ui-state-default ui-corner-all' href='#'></a>",
64+
handles = [];
6465
this.jslider || (this.jslider = o.jslider);
6566
this._keySliding = false;
6667
this._mouseSliding = false;
@@ -178,15 +179,15 @@
178179

179180
handleCount = (o.values && o.values.length) || 1;
180181

181-
for (i = 0; i < handleCount; i++) {
182+
for (var i = 0; i < handleCount; i++) {
182183
handles.push(handle);
183184
}
184185

185186
this.handles = existingHandles.add($(
186187
handles.join(""))
187188
.appendTo(this.element));
188189

189-
for (i = 0; i < handleCount; i++) {
190+
for (var i = 0; i < handleCount; i++) {
190191
handle = this.handles[i];
191192
handle.index = i;
192193
J2S.setDraggable(handle, [ fDown, fDrag,
@@ -236,7 +237,7 @@
236237

237238
_destroy : function() {
238239

239-
for (i = 0; i < this.handles.length; i++) {
240+
for (var i = 0; i < this.handles.length; i++) {
240241
J2S.setDraggable(this.handles[i], false);
241242
}
242243

@@ -511,7 +512,7 @@
511512
if ($.isArray(arguments[0])) {
512513
vals = this.options.values;
513514
newValues = arguments[0];
514-
for (i = 0; i < vals.length; i += 1) {
515+
for (var i = 0; i < vals.length; i += 1) {
515516
vals[i] = this
516517
._trimAlignValue(newValues[i]);
517518
this._change(null, i);
@@ -568,7 +569,7 @@
568569
case "values":
569570
this._animateOff = true;
570571
this._refreshValue();
571-
for (i = 0; i < valsLength; i += 1) {
572+
for (var i = 0; i < valsLength; i += 1) {
572573
this._change(null, i);
573574
}
574575
this._animateOff = false;
@@ -817,4 +818,4 @@
817818
})(J2S.__$);
818819

819820
})();
820-
// BH 9/15/2018
821+
// BH 12/17/2018

0 commit comments

Comments
 (0)