From f0dcbc8db825f07b9a550633f3f6417dc613f831 Mon Sep 17 00:00:00 2001 From: schettino72 Date: Sun, 6 Jan 2013 15:28:23 +0800 Subject: [PATCH] Datepicker: focus on next element after selecting date. Fixed #7765 - Datepicker: Focus not placed back into textbox after date selection --- ui/jquery.ui.datepicker.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index 6f187ecaad7..f61c6b54fe9 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -1014,12 +1014,8 @@ $.extend(Datepicker.prototype, { if (inst.inline){ this._updateDatepicker(inst); } else { + inst.input.focus(); this._hideDatepicker(); - this._lastInput = inst.input[0]; - if (typeof(inst.input[0]) !== "object") { - inst.input.focus(); // restore focus - } - this._lastInput = null; } },