aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJörn Zaefferer <joern.zaefferer@gmail.com>2013-12-09 13:02:19 +0100
committerJörn Zaefferer <joern.zaefferer@gmail.com>2013-12-09 13:02:19 +0100
commit3e57b29267a8cf0e2ff72711e1ce06432961dcdf (patch)
tree9fb70cea10e732ae2def693e3e8030f2376ac096
parent8033cf4a5a33ce65a836e36754ee28da671a3f0c (diff)
downloadjquery-ui-3e57b29267a8cf0e2ff72711e1ce06432961dcdf.tar.gz
jquery-ui-3e57b29267a8cf0e2ff72711e1ce06432961dcdf.zip
JSCS config: Set requireSpaceBeforeBinaryOperators, fix occurences
-rw-r--r--.jscs.json1
-rw-r--r--Gruntfile.js2
-rw-r--r--ui/jquery.ui.mouse.js10
3 files changed, 7 insertions, 6 deletions
diff --git a/.jscs.json b/.jscs.json
index b78228431..f832638f4 100644
--- a/.jscs.json
+++ b/.jscs.json
@@ -12,6 +12,7 @@
"requireSpacesInsideArrayBrackets": "all",
"disallowLeftStickedOperators": [ "?", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<=" ],
"disallowRightStickedOperators": [ "?", "/", "*", ":", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
+ "requireSpaceBeforeBinaryOperators": ["+", "-", "/", "*", "=", "==", "===", "!=", "!=="],
"requireRightStickedOperators": [ "!" ],
"requireLeftStickedOperators": [ "," ],
"disallowKeywords": [ "with" ],
diff --git a/Gruntfile.js b/Gruntfile.js
index 242f3459f..31b21d910 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -124,7 +124,7 @@ function createBanner( files ) {
return "/*! <%= pkg.title || pkg.name %> - v<%= pkg.version %> - " +
"<%= grunt.template.today('isoDate') %>\n" +
"<%= pkg.homepage ? '* ' + pkg.homepage + '\\n' : '' %>" +
- (files ? "* Includes: " + fileNames.join(", ") + "\n" : "")+
+ (files ? "* Includes: " + fileNames.join(", ") + "\n" : "") +
"* Copyright <%= grunt.template.today('yyyy') %> <%= pkg.author.name %>;" +
" Licensed <%= _.pluck(pkg.licenses, 'type').join(', ') %> */\n";
}
diff --git a/ui/jquery.ui.mouse.js b/ui/jquery.ui.mouse.js
index 36b9f2ba0..ce1ecca72 100644
--- a/ui/jquery.ui.mouse.js
+++ b/ui/jquery.ui.mouse.js
@@ -29,10 +29,10 @@ $.widget("ui.mouse", {
var that = this;
this.element
- .bind("mousedown."+this.widgetName, function(event) {
+ .bind("mousedown." + this.widgetName, function(event) {
return that._mouseDown(event);
})
- .bind("click."+this.widgetName, function(event) {
+ .bind("click." + this.widgetName, function(event) {
if (true === $.data(event.target, that.widgetName + ".preventClickEvent")) {
$.removeData(event.target, that.widgetName + ".preventClickEvent");
event.stopImmediatePropagation();
@@ -46,11 +46,11 @@ $.widget("ui.mouse", {
// TODO: make sure destroying one instance of mouse doesn't mess with
// other instances of mouse
_mouseDestroy: function() {
- this.element.unbind("."+this.widgetName);
+ this.element.unbind("." + this.widgetName);
if ( this._mouseMoveDelegate ) {
this.document
- .unbind("mousemove."+this.widgetName, this._mouseMoveDelegate)
- .unbind("mouseup."+this.widgetName, this._mouseUpDelegate);
+ .unbind("mousemove." + this.widgetName, this._mouseMoveDelegate)
+ .unbind("mouseup." + this.widgetName, this._mouseUpDelegate);
}
},