@@ -127,6 +127,7 @@ function Datepicker() {
127
127
onSelect : null , // Define a callback function when a date is selected
128
128
onChangeMonthYear : null , // Define a callback function when the month or year is changed
129
129
onClose : null , // Define a callback function when the datepicker is closed
130
+ onUpdateDatepicker : null , // Define a callback function when the datepicker is updated
130
131
numberOfMonths : 1 , // Number of months to show at a time
131
132
showCurrentAtPos : 0 , // The position in multipe months at which to show the current month (starting at 0)
132
133
stepMonths : 1 , // Number of months to step back/forward
@@ -808,7 +809,8 @@ $.extend(Datepicker.prototype, {
808
809
numMonths = this . _getNumberOfMonths ( inst ) ,
809
810
cols = numMonths [ 1 ] ,
810
811
width = 17 ,
811
- activeCell = inst . dpDiv . find ( "." + this . _dayOverClass + " a" ) ;
812
+ activeCell = inst . dpDiv . find ( "." + this . _dayOverClass + " a" ) ,
813
+ onUpdateDatepicker = $ . datepicker . _get ( inst , "onUpdateDatepicker" ) ;
812
814
813
815
if ( activeCell . length > 0 ) {
814
816
datepicker_handleMouseover . apply ( activeCell . get ( 0 ) ) ;
@@ -838,6 +840,10 @@ $.extend(Datepicker.prototype, {
838
840
origyearshtml = inst . yearshtml = null ;
839
841
} , 0 ) ;
840
842
}
843
+
844
+ if ( onUpdateDatepicker ) {
845
+ onUpdateDatepicker . apply ( ( inst . input ? inst . input [ 0 ] : null ) , [ inst ] ) ;
846
+ }
841
847
} ,
842
848
843
849
// #6694 - don't focus the input if it's already focused
0 commit comments