Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#11485 closed defect (fixed)

TimeTextBox: strange sorting on filtered results

Reported by: bill Owned by: Douglas Hays
Priority: high Milestone: 1.6
Component: Dijit - Form Version: 1.5
Keywords: Cc:
Blocked By: Blocking:


See test_TimeTextBox.html, and type "13" into the 24 hour TimeTextBox. I'd expect it to filter down to times that start with "13", in chronological order, but the actual order displayed is:


Attachments (1)

ttb.png (14.5 KB) - added by bill 11 years ago.

Download all attachments as: .zip

Change History (10)

Changed 11 years ago by bill

Attachment: ttb.png added


comment:1 Changed 11 years ago by Douglas Hays

TimeTextBox? always loops through times, so after 13:45 would come 13:00. Hovering over the arrow will make it loop. Do you want the looping to stop (and the arrows to be removed as well)?

comment:2 Changed 11 years ago by bill

I guess the question is why it starts at 13:30, rather than 13:00.

comment:3 Changed 11 years ago by bill

(In [22580]) Various [stop gap] fixes to TimeTextBox, although still wondering about full rewrite as per #7631, or replacing custom scrolling with native scrollbar like ComboBox has. Fixes include:

  • limit drop down to 10 entries so that (in the majority of cases) it won't overlap the <input> box (fixes #8387)
  • same as ComboBox, make typing automatically open the dropdown, and once the user has started typing or backspacing the dropdown list is filtered by what's in the <input> (fixes #11486)
  • fix recently introduced problem (with _HasDropDown conversion of _DateTimeTextBox, refs #6416) where drop down becomes detached from <input> when it appears above the input and then user types text to further filter the values shown
  • add more tests for TimeTextBox; they previous tests were very sparse; tests include check of current filtering sort order (refs #11485)

!strict as usual.

comment:4 Changed 11 years ago by Douglas Hays

Milestone: tbd1.6

bill, I couldn't recreate this after [22580].

comment:5 Changed 11 years ago by Douglas Hays

Resolution: fixed
Status: newclosed

Full-rewrite aside, please reopen if there's still a scenario that does not filter correctly.

comment:6 Changed 11 years ago by bill

The issue was with sorting, not filtering. AFAIK filtering is working fine.

What's the expected sorting behavior of the current code? In the "12 Hour Time" example in test_TimeTextBox.html, when I enter "4" in the <input> the drop down opens centered at 4AM, but when I enter 5 it centers on 5PM. This seems random. Your results may vary depending on your timezone or the time of day when you run the test. (I ran my test in Japanese timezone at 12:25PM, on FF3.6/win)

comment:7 Changed 11 years ago by Douglas Hays

Resolution: fixed
Status: closedreopened

comment:8 Changed 11 years ago by Douglas Hays

Resolution: fixed
Status: reopenedclosed

(In [22818]) Fixes #11485. Order time picker list and remove wrapping support. Fix automated tst to reflect sorted order. !strict

comment:9 Changed 11 years ago by bill

Component: DijitDijit - Form
Note: See TracTickets for help on using tickets.