Opened 14 years ago

Closed 10 years ago

#4453 closed bug (fixed)

UI Datepicker inside UI Dialog Issue

Reported by: JBeckton Owned by:
Priority: minor Milestone: 1.8
Component: ui.datepicker Version: 1.7.1
Keywords: Cc:
Blocked by: Blocking:

Description

I noticed that when using the date picker on a form field inside a tabs container wrapped by a dialog I get a slightly different behavior then when using the date picker on a form in the page without the tabs and dialog.

It appears that the date picker is call on focus and when a date is selected and it populates the form field the field is then blurred so you can click on it again and change the date.

Inside the dialog it seems the field is not getting blurred when the date is set so in order to change the date after just setting it I have to click out of the field on the page somewhere to blur the field before I can activate the picker again on focus.

Change History (8)

comment:1 Changed 14 years ago by Jörn Zaefferer

Milestone: TBD1.7.2

comment:2 Changed 14 years ago by Jörn Zaefferer

Milestone: 1.7.21.8

comment:3 Changed 13 years ago by btburnett3

Partially fixed by r3757

Described problem (input not blurring when a date is clicked) has been fixed. The problem was the overlay canceling the click event, so the input was never blurred by the click outside the input. Now that clicks inside the datepicker are not canceled, the problem is fixed.

However, during testing I noticed some other related problems. Clicks on the overlay have the same behavior, the datepicker closes but the field is not blurred. Additionally, clicks on the close button of the dialog do not close the datepicker at all.

comment:4 Changed 13 years ago by btburnett3

Fixed by r3759

Changed overlay to not stop propagation of events on the dialog overlay itself. They don't do anything anyway, and allowing them to propagate causes input to blur correctly.

Datepicker now tests to see if its in a dialog and binds to the dialog's close event so that it can hide the datepicker when the dialog is closed. It could have also been fixed by removing the .stopPropagation on the close buttons mousedown event, but I assume that the stopPropagation must have been in there for a reason since it's the only activity in the mousedown event.

comment:5 Changed 13 years ago by btburnett3

More work in r3762

No longer attaches to close event of dialog to detect dialog close. Instead, dialog change to not stop propagation of mouse down event on the close button.

comment:6 Changed 13 years ago by rdworth

Summary: UI Date Picker inside UI Dialog IssueUI Datepicker inside UI Dialog Issue

comment:7 Changed 10 years ago by Scott González

Milestone: 1.9.01.11.0

comment:8 Changed 10 years ago by mikesherov

Milestone: 1.11.01.8
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.