Last Comment Bug 325235 - Inconsistent unselect behavior in richlistbox
: Inconsistent unselect behavior in richlistbox
Status: RESOLVED WORKSFORME
:
Product: Toolkit
Classification: Components
Component: XUL Widgets (show other bugs)
: unspecified
: All All
-- minor (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
:
: Neil Deakin
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-01-30 08:17 PST by Simon Bünzli
Modified: 2007-01-23 11:30 PST (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments

Description User image Simon Bünzli 2006-01-30 08:17:46 PST
According to bug 325159, Ctrl+Click should unselect the selected item in a richlistbox. The keyboard equivalent to this is Ctrl+Space which in this case doesn't work. OTOH listbox doesn't allow an item to be deselected (nor does tree nor does HTMLSelect) in single-select mode.

Should this behavior really be expected of richlistbox, Ctrl+Space must be added. However I'd rather vote for listbox/tree/HTMLSelect consistency and remove Ctrl+Click - since this is no necessary functionality for the Extensions/Themes/Downloads managers and since in the future it might be desirable to force a richlistbox to have one (and only one) item selected - as currently done by HTMLSelect on e.g. this "Enter Bug" page for component selection (think listbox as radio options vs. listbox as checkbox options).

If however Ctrl+Space should be added, please file a seperate bug for listbox for adding the same functionality (since I currently don't see substantial enough a difference between listbox and richlistbox for allowing such unexpected differences). Of course, I'm biased - I wrote the patch for bug 298371 to make richlistbox inherit directly from listbox for improved feature parity.
Comment 1 User image Matthew Waymost 2006-01-30 09:14:12 PST
I'm replying to your comment in bug 325159 here, since that bug is closed up and the relevant place for discussion is here.

IMO, the Ctrl+click behavior to deselect is perfectly consistent. <richlistbox> doesn't support multiple selection; however, <listbox> does support multiple selection, and you do use Ctrl+click to both select and deselect items. So, to me, it logically follows that Ctrl+click would deselect the selected item in <richlistbox>, its lack of multiple selection support notwithstanding.

How useful is it to deselect a richlistitem? Admittedly, not very. However, the code is there and, I agree, that <richlistbox> and <listbox> should work as similarly as possible. So, I think that Ctrl+space should be added as a way to deselect a <richlistitem> on top of the Ctrl+click functionality. As I see it, that would be the most consistent implementation.

And thank you for being willing to address this issue in your next version of Console², as unimportant as it may be.
Comment 2 User image Simon Bünzli 2006-01-30 09:29:38 PST
To make the point clear: listbox does support item deselecting only in multiple-select mode and *not* in single-select mode. For consistency, I'd expect the same behavior of richlistbox (where multiple-selection is coming in the mentioned bug 298371).

And should you add Ctrl+click deselecting, you'd severly hinder the mentioned functionality of using (rich)listboxes as a radio-style element. IMO this is not worth it.
Comment 3 User image alexander :surkov 2007-01-23 01:29:09 PST
Can the bug be closed?
Comment 4 User image Simon Bünzli 2007-01-23 11:30:36 PST
WORKSFORME as of 2007-01-17 thanks to the fix for bug 298371.

Note You need to log in before you can comment on or make changes to this bug.