Ticket #3272 (new task)

Opened 18 months ago

Last modified 11 days ago

ComboBox: standardize dropdown placement

Reported by: bill Owned by: haysmark
Priority: normal Milestone: 1.4
Component: Dijit Version: 0.9
Severity: normal Keywords:
Cc:

Description

The drop down list can flutter between being above and below the <input> box depending on how much room there is on each side _and_ how much data is in the list. As you type the position can switch.

Since our drop downs auto-size to the space available, let's make the drop down always go below the <input> box, unless the space below the input box is really cramped (say, less that 100px).

Attachments

3272.patch (1.2 kB) - added by haysmark 14 months ago.
place.js checks all possible popup positions to see where there is the most viewable space, making popup placement more consistent. Fixes #3272.

Change History

Changed 16 months ago by bill

  • summary changed from Autocompleter/Select: standardize dropdown placement to ComboBox: standardize dropdown placement

Changed 15 months ago by haysmark

EXT flutters too:

http://www.extjs.com/deploy/ext/examples/form/combos.html

Fluttering is the industry standard; why deviate?

Changed 14 months ago by doughays

I think always going to the largest area will prevent flutter, be easy to program, and minimize user scrolling.

Changed 14 months ago by haysmark

Ok, so right now the placement code prioritizes placement based on a first come first serve basis. place is called with the bottom position first so that is why we see fluttering. If we removed that part of the code it would stick to the largest area.

Changed 14 months ago by bill

The placement code works correctly for most drop downs, like Calendar or Menus. This is a special case because the drop down list is of a variable height (ie, unlike Calendar, it needs a scrollbar). So let's not change the drop down code for the general case.

As per Doug's suggestion to always go to the largest area, I posted http://dojotoolkit.org/forum/dijit-dijit-0-9/dijit-development-discussion/drop-down-placement-combobox-filteringselect-soli to see what others thing. Like to get some more input on this.

Changed 14 months ago by haysmark

place.js checks all possible popup positions to see where there is the most viewable space, making popup placement more consistent. Fixes #3272.

Changed 14 months ago by haysmark

Bill I changed the patch I sent you. Because I removed the break in place.js I had to make sure tooltip-type popups exit the code with the "best" orientation at the end.

Changed 14 months ago by haysmark

You know I'm concerned that my algorithm messes up the Menu test because any submenus that you open on the right half of the page appear to the left no matter what.

Changed 14 months ago by haysmark

And similarly I think it would be really arbitrary for submenus to start popping to the left or on top when you still have 100px available to you.

Changed 13 months ago by bill

  • milestone changed from 1.0 to 2.0

Changed 10 months ago by alex

  • milestone changed from 2.0 to 1.3

Milestone 2.0 deleted

Changed 11 days ago by bill

  • milestone changed from 1.3 to 1.4

bumping 1.4 tickets to 1.5, and most 1.3 tickets to 1.4

Note: See TracTickets for help on using tickets.