@@ -882,26 +882,13 @@ $.extend(Datepicker.prototype, {
882
882
_selectMonthYear : function ( id , select , period ) {
883
883
var target = $ ( id ) ;
884
884
var inst = this . _getInst ( target [ 0 ] ) ;
885
- inst . _selectingMonthYear = false ;
886
885
inst [ 'selected' + ( period == 'M' ? 'Month' : 'Year' ) ] =
887
886
inst [ 'draw' + ( period == 'M' ? 'Month' : 'Year' ) ] =
888
887
parseInt ( select . options [ select . selectedIndex ] . value , 10 ) ;
889
888
this . _notifyChange ( inst ) ;
890
889
this . _adjustDate ( target ) ;
891
890
} ,
892
891
893
- /* Restore input focus after not changing month/year. */
894
- _clickMonthYear : function ( id ) {
895
- var target = $ ( id ) ;
896
- var inst = this . _getInst ( target [ 0 ] ) ;
897
- if ( inst . input && inst . _selectingMonthYear ) {
898
- setTimeout ( function ( ) {
899
- inst . input . focus ( ) ;
900
- } , 0 ) ;
901
- }
902
- inst . _selectingMonthYear = ! inst . _selectingMonthYear ;
903
- } ,
904
-
905
892
/* Action for selecting a day. */
906
893
_selectDay : function ( id , month , year , td ) {
907
894
var target = $ ( id ) ;
@@ -1610,7 +1597,6 @@ $.extend(Datepicker.prototype, {
1610
1597
var inMaxYear = ( maxDate && maxDate . getFullYear ( ) == drawYear ) ;
1611
1598
monthHtml += '<select class="ui-datepicker-month" ' +
1612
1599
'onchange="DP_jQuery_' + dpuuid + '.datepicker._selectMonthYear(\'#' + inst . id + '\', this, \'M\');" ' +
1613
- 'onclick="DP_jQuery_' + dpuuid + '.datepicker._clickMonthYear(\'#' + inst . id + '\');"' +
1614
1600
'>' ;
1615
1601
for ( var month = 0 ; month < 12 ; month ++ ) {
1616
1602
if ( ( ! inMinYear || month >= minDate . getMonth ( ) ) &&
@@ -1644,7 +1630,6 @@ $.extend(Datepicker.prototype, {
1644
1630
endYear = ( maxDate ? Math . min ( endYear , maxDate . getFullYear ( ) ) : endYear ) ;
1645
1631
inst . yearshtml += '<select class="ui-datepicker-year" ' +
1646
1632
'onchange="DP_jQuery_' + dpuuid + '.datepicker._selectMonthYear(\'#' + inst . id + '\', this, \'Y\');" ' +
1647
- 'onclick="DP_jQuery_' + dpuuid + '.datepicker._clickMonthYear(\'#' + inst . id + '\');"' +
1648
1633
'>' ;
1649
1634
for ( ; year <= endYear ; year ++ ) {
1650
1635
inst . yearshtml += '<option value="' + year + '"' +
0 commit comments