From 1aa069bc2e028e78c65853b088fd1d94a83b53e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Malbr=C3=A1n?= Date: Fri, 2 Aug 2013 19:09:29 -0300 Subject: [PATCH 1/2] Update JSLint submodule to the commit we were using before switching to a submodule --- src/extensions/default/JSLint/thirdparty/jslint | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/extensions/default/JSLint/thirdparty/jslint b/src/extensions/default/JSLint/thirdparty/jslint index eec32d4b4bc..2347ec449b1 160000 --- a/src/extensions/default/JSLint/thirdparty/jslint +++ b/src/extensions/default/JSLint/thirdparty/jslint @@ -1 +1 @@ -Subproject commit eec32d4b4bc7945672c49a5ffdf4dc6c87b7058b +Subproject commit 2347ec449b14eb3a4935daeaaa3ef036d42dd96d From 88948cfbf351e8a28bb616eabcff3256bd566706 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Malbr=C3=A1n?= Date: Fri, 2 Aug 2013 20:01:05 -0300 Subject: [PATCH 2/2] Revert some recently added unneded JSLint fixes --- test/spec/CSSUtils-test.js | 18 ++++++++++-------- test/spec/Menu-test.js | 36 ++++++++++++++++-------------------- 2 files changed, 26 insertions(+), 28 deletions(-) diff --git a/test/spec/CSSUtils-test.js b/test/spec/CSSUtils-test.js index 93305f58ee6..f8df31facfc 100644 --- a/test/spec/CSSUtils-test.js +++ b/test/spec/CSSUtils-test.js @@ -973,10 +973,10 @@ define(function (require, exports, module) { // Braces inside string; string inside rule (not inside selector) css = "a::after { content: ' {' attr(href) '}'; } \n" + - ".foo { color:red } \n" + - "a::after { content: \" {\" attr(href) \"}\"; } \n" + - "li::before { content: \"} h4 { color:black }\"; } \n" + - "div { color:green }"; + ".foo { color:red } \n" + + "a::after { content: \" {\" attr(href) \"}\"; } \n" + + "li::before { content: \"} h4 { color:black }\"; } \n" + + "div { color:green }"; result = match(css, { tag: "a" }); expect(result.length).toBe(2); @@ -999,7 +999,8 @@ define(function (require, exports, module) { expect(result.length).toBe(1); css = "@import \"null?\\\"{\"; \n" + // a real-world CSS hack similar to the above case - "div { color: red }"; + "div { color: red }"; + result = match(css, { tag: "div" }); expect(result.length).toBe(1); @@ -1051,9 +1052,10 @@ define(function (require, exports, module) { expect(result.length).toBe(1); css = ".foo\n" + - "{\n" + - " color: red;\n" + - "}"; + "{\n" + + " color: red;\n" + + "}"; + result = match(css, { clazz: "foo" }); expect(result.length).toBe(1); }); diff --git a/test/spec/Menu-test.js b/test/spec/Menu-test.js index 83f1dc89684..83a06d9396c 100644 --- a/test/spec/Menu-test.js +++ b/test/spec/Menu-test.js @@ -129,21 +129,19 @@ define(function (require, exports, module) { function getBounds(object) { return { - left: object.offset().left, - top: object.offset().top, - right: object.offset().left + object.width(), - bottom: object.offset().top + object.height() + left : object.offset().left, + top : object.offset().top, + right : object.offset().left + object.width(), + bottom : object.offset().top + object.height() }; } function boundsInsideWindow(object) { var bounds = getBounds(object); - return ( - bounds.left >= 0 && - bounds.right <= $(testWindow).width() && - bounds.top >= 0 && - bounds.bottom <= $(testWindow).height() - ); + return bounds.left >= 0 && + bounds.right <= $(testWindow).width() && + bounds.top >= 0 && + bounds.bottom <= $(testWindow).height(); } it("context menu is not clipped", function () { @@ -762,21 +760,19 @@ define(function (require, exports, module) { function getBounds(object) { return { - left: object.offset().left, - top: object.offset().top, - right: object.offset().left + object.width(), - bottom: object.offset().top + object.height() + left : object.offset().left, + top : object.offset().top, + right : object.offset().left + object.width(), + bottom : object.offset().top + object.height() }; } function boundsInsideWindow(object) { var bounds = getBounds(object); - return ( - bounds.left >= 0 && - bounds.right <= $(testWindow).width() && - bounds.top >= 0 && - bounds.bottom <= $(testWindow).height() - ); + return bounds.left >= 0 && + bounds.right <= $(testWindow).width() && + bounds.top >= 0 && + bounds.bottom <= $(testWindow).height(); } it("context menu is not clipped", function () {