Robin Herbots 12 年 前
コミット
ce6f27d11c

+ 1 - 1
build.properties

@@ -7,7 +7,7 @@ distdir = dist
 
 build.major = 2
 build.minor = 2
-build.revision = 61
+build.revision = 63
 
 target = jquery.inputmask.bundle.js
 target.min = jquery.inputmask.bundle.min.js

+ 1 - 1
component.json

@@ -1,6 +1,6 @@
 {
     "name": "jquery.inputmask",
-    "version": "2.2.61",
+    "version": "2.2.63",
     "main": "./dist/jquery.inputmask.bundle.js",
     "dependencies": {
         "jquery": ">=1.5"

BIN
dist/jQuery.InputMask.2.2.61.nupkg


BIN
dist/jQuery.InputMask.2.2.63.nupkg


+ 20 - 20
dist/jquery.inputmask.bundle.js

@@ -3,7 +3,7 @@
 * http://github.com/RobinHerbots/jquery.inputmask
 * Copyright (c) 2010 - 2013 Robin Herbots
 * Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-* Version: 2.2.61
+* Version: 2.2.63
 */
 
 (function ($) {
@@ -1429,7 +1429,7 @@
                                                 if (isComplete(buffer))
                                                     $input.trigger("complete");
                                             }, 0);
-                                        } else {
+                                        } else if (isSelection) {
                                             getActiveMaskSet()["buffer"] = getActiveMaskSet()["undoBuffer"].split('');
                                         }
                                     }
@@ -1465,7 +1465,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.2.61
+Version: 2.2.63
 
 Optional extensions on the jquery.inputmask base
 */
@@ -1567,7 +1567,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2012 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.2.61
+Version: 2.2.63
 
 Optional extensions on the jquery.inputmask base
 */
@@ -2036,7 +2036,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.2.61
+Version: 2.2.63
 
 Optional extensions on the jquery.inputmask base
 */
@@ -2100,12 +2100,12 @@ Optional extensions on the jquery.inputmask base
                 return reformatOnly ? pos : newPos <= radixPos || (opts.skipRadixDance && newPos != 0) ? newPos - 1 : newPos;
             },
             regex: {
-                number: function (groupSeparator, groupSize, radixPoint, digits, allowPlus, allowMinus) {
-                    var escapedGroupSeparator = $.inputmask.escapeRegex.call(this, groupSeparator);
-                    var escapedRadixPoint = $.inputmask.escapeRegex.call(this, radixPoint);
-                    var digitExpression = isNaN(digits) ? digits : '{0,' + digits + '}';
-                    var signedExpression = "[" + (allowPlus ? "\+" : "") + (allowMinus ? "-" : "") + "]?";
-                    return new RegExp("^" + signedExpression + "(\\d+|\\d{1," + groupSize + "}((" + escapedGroupSeparator + "\\d{" + groupSize + "})?)+)(" + escapedRadixPoint + "\\d" + digitExpression + ")?$");
+                number: function (opts) {
+                    var escapedGroupSeparator = $.inputmask.escapeRegex.call(this, opts.groupSeparator);
+                    var escapedRadixPoint = $.inputmask.escapeRegex.call(this, opts.radixPoint);
+                    var digitExpression = isNaN(opts.digits) ? opts.digits : '{0,' + opts.digits + '}';
+                    var signedExpression = "[" + (opts.allowPlus ? "\+" : "") + (opts.allowMinus ? "-" : "") + "]?";
+                    return new RegExp("^" + signedExpression + "(\\d+|\\d{1," + opts.groupSize + "}((" + escapedGroupSeparator + "\\d{" + opts.groupSize + "})?)+)(" + escapedRadixPoint + "\\d" + digitExpression + ")?$");
                 }
             },
             onKeyDown: function (e, buffer, opts) {
@@ -2142,11 +2142,11 @@ Optional extensions on the jquery.inputmask base
                             var escapedGroupSeparator = $.inputmask.escapeRegex.call(this, opts.groupSeparator);
                             bufferStr = bufferStr.replace(new RegExp(escapedGroupSeparator, "g"), '');
                         }
-                        var isValid = opts.regex.number(opts.groupSeparator, opts.groupSize, opts.radixPoint, opts.digits, opts.allowPlus, opts.allowMinus).test(bufferStr);
+                        var isValid = opts.regex.number(opts).test(bufferStr);
                         if (!isValid) {
                             //let's help the regex a bit
                             bufferStr += "0";
-                            isValid = opts.regex.number(opts.groupSeparator, opts.groupSize, opts.radixPoint, opts.digits, opts.allowPlus, opts.allowMinus).test(bufferStr);
+                            isValid = opts.regex.number(opts).test(bufferStr);
                             if (!isValid) {
                                 //make a valid group
                                 var lastGroupSeparator = bufferStr.lastIndexOf(opts.groupSeparator);
@@ -2154,10 +2154,10 @@ Optional extensions on the jquery.inputmask base
                                     bufferStr += "0";
                                 }
 
-                                isValid = opts.regex.number(opts.groupSeparator, opts.groupSize, opts.radixPoint, opts.digits, opts.allowPlus, opts.allowMinus).test(bufferStr);
+                                isValid = opts.regex.number(opts).test(bufferStr);
                                 if (!isValid && !strict) {
                                     if (chrs == opts.radixPoint) {
-                                        isValid = opts.regex.number(opts.groupSeparator, opts.groupSize, opts.radixPoint, opts.digits, opts.allowPlus, opts.allowMinus).test("0" + bufferStr + "0");
+                                        isValid = opts.regex.number(opts).test("0" + bufferStr + "0");
                                         if (isValid) {
                                             buffer[pos] = "0";
                                             pos++;
@@ -2184,10 +2184,10 @@ Optional extensions on the jquery.inputmask base
         },
         'integer': {
             regex: {
-                number: function (groupSeparator, groupSize, radixPoint, digits, allowPlus, allowMinus) {
-                    var escapedGroupSeparator = $.inputmask.escapeRegex.call(this, groupSeparator);
-                    var signedExpression = "[" + (allowPlus ? "\+" : "") + (allowMinus ? "-" : "") + "]?";
-                    return new RegExp("^" + signedExpression + "(\\d+|\\d{1," + groupSize + "}((" + escapedGroupSeparator + "\\d{" + groupSize + "})?)+)$");
+                number: function (opts) {
+                    var escapedGroupSeparator = $.inputmask.escapeRegex.call(this, opts.groupSeparator);
+                    var signedExpression = "[" + (opts.allowPlus ? "\+" : "") + (opts.allowMinus ? "-" : "") + "]?";
+                    return new RegExp("^" + signedExpression + "(\\d+|\\d{1," + opts.groupSize + "}((" + escapedGroupSeparator + "\\d{" + opts.groupSize + "})?)+)$");
                 }
             },
             alias: "decimal"
@@ -2199,7 +2199,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.2.61
+Version: 2.2.63
 
 Regex extensions on the jquery.inputmask base
 Allows for using regular expressions as a mask

ファイルの差分が大きいため隠しています
+ 64 - 64
dist/jquery.inputmask.bundle.min.js


ファイルの差分が大きいため隠しています
+ 2 - 2
dist/min/jquery.inputmask.js


ファイルの差分が大きいため隠しています
+ 6 - 7
dist/min/jquery.inputmask.numeric.extensions.js


+ 1 - 1
jquery.inputmask.jquery.json

@@ -8,7 +8,7 @@
 		"inputmask",
 		"mask"
     ],
-    "version": "2.2.61",
+    "version": "2.2.63",
     "author": {
         "name": "Robin Herbots",
         "url": "http://github.com/RobinHerbots/jquery.inputmask"