]> source.dussan.org Git - jquery-ui.git/commitdiff
Fixed #3859 - Datepicker can't pick years before 1999
authorKeith Wood <kbwood.au@gmail.com>
Mon, 19 Jan 2009 10:06:49 +0000 (10:06 +0000)
committerKeith Wood <kbwood.au@gmail.com>
Mon, 19 Jan 2009 10:06:49 +0000 (10:06 +0000)
ui/ui.datepicker.js

index a8ccd8ef39babe3c3a23feb293d9cd4714e7aa41..6ec694e478316d216cb7d95d1a39293fc1c494c9 100644 (file)
@@ -1450,9 +1450,8 @@ $.extend(Datepicker.prototype, {
                                year = drawYear - 10;
                                endYear = drawYear + 10;
                        } else if (years[0].charAt(0) == '+' || years[0].charAt(0) == '-') {
-                               year = endYear = new Date().getFullYear();
-                               year += parseInt(years[0], 10);
-                               endYear += parseInt(years[1], 10);
+                               year = drawYear + parseInt(years[0], 10);
+                               endYear = drawYear + parseInt(years[1], 10);
                        } else {
                                year = parseInt(years[0], 10);
                                endYear = parseInt(years[1], 10);