Skip to content

Commit

Permalink
Datepicker: Fixed keyboard navigation
Browse files Browse the repository at this point in the history
Fixes #7956
Closes gh-1677
  • Loading branch information
piotros authored and scottgonzalez committed Mar 30, 2016
1 parent 882eb4c commit bf5d6f3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ui/widgets/datepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -1913,8 +1913,8 @@ $.extend( Datepicker.prototype, {

/* Adjust one of the date sub-fields. */
_adjustInstDate: function( inst, offset, period ) {
var year = inst.drawYear + ( period === "Y" ? offset : 0 ),
month = inst.drawMonth + ( period === "M" ? offset : 0 ),
var year = inst.selectedYear + ( period === "Y" ? offset : 0 ),
month = inst.selectedMonth + ( period === "M" ? offset : 0 ),
day = Math.min( inst.selectedDay, this._getDaysInMonth( year, month ) ) + ( period === "D" ? offset : 0 ),
date = this._restrictMinMax( inst, this._daylightSavingAdjust( new Date( year, month, day ) ) );

Expand Down

0 comments on commit bf5d6f3

Please sign in to comment.