From 98f7e6a8d615772fbddbf185241d087a95e5e121 Mon Sep 17 00:00:00 2001 From: pheiberg Date: Wed, 24 Nov 2010 19:17:23 +0100 Subject: [PATCH] Datepicker: made it possible to select a date in the selected month using enter. Fixes #5527 - Datepicker: Problem selecting the date with keyboard shorcuts --- ui/jquery.ui.datepicker.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index ed2ab0600..519b8a913 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -500,8 +500,8 @@ $.extend(Datepicker.prototype, { case 9: $.datepicker._hideDatepicker(); handled = false; break; // hide on tab out - case 13: var sel = $('td.' + $.datepicker._dayOverClass, inst.dpDiv). - add($('td.' + $.datepicker._currentClass, inst.dpDiv)); + case 13: var sel = $('td.' + $.datepicker._dayOverClass + ':not(.' + + $.datepicker._currentClass + ')', inst.dpDiv); if (sel[0]) $.datepicker._selectDay(event.target, inst.selectedMonth, inst.selectedYear, sel[0]); else -- 2.39.5