Skip to content

Commit dd43a0f

Browse files
committed
Removed refocus from IE as it was causing problems.
On all other browsers, the focus is restored to datebox after clicking a date. I could not get this working in IE.
1 parent 1d17c3f commit dd43a0f

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/dateinput/dateinput.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,10 @@
275275
currMonth = date.getMonth();
276276
currDay = date.getDate();
277277

278+
// focus the input after selection (doesn't work in IE)
279+
if (e.type == "click" && !$.browser.msie) {
280+
input.focus();
281+
}
278282

279283
// change
280284
e = e || $.Event("api");
@@ -638,9 +642,7 @@
638642
if (e.isDefaultPrevented()) { return; }
639643

640644
$(document).unbind("click.d").unbind("keydown.d");
641-
input.focus();
642-
input.select();
643-
645+
644646
// do the hide
645647
root.hide();
646648
opened = false;

0 commit comments

Comments
 (0)