Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 324475 - Deselect by ctrl-click not working on jFace viewer
Summary: Deselect by ctrl-click not working on jFace viewer
Status: RESOLVED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-03 14:36 EDT by Josh O'Dowd CLA
Modified: 2010-09-07 09:52 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Josh O'Dowd CLA 2010-09-03 14:36:29 EDT
Build Identifier: 

Greetings:

I have a jFace TreeViewer that I have given a style bit of SWT.SINGLE. It will not allow a tree element to be deselected using ctrl-click on the selected element.

I did find that deselect works if the style bit is set to SWT.MULTI

In my case I need SINGLE select only, with the ability to deselect an element, putting the tree in a no selection state.

I am using eclipse plugin development with eclipse 3.6

Any thoughts??

Thanks for your time.

Reproducible: Always
Comment 1 Curtis Windatt CLA 2010-09-03 14:46:49 EDT
I am pretty sure this is the default and expected behaviour when using single select.  Moving to platform UI for comment.

I expect that the best solution would be to use multi select and override the selection behaviour to deselect everything except the one item being clicked on.
Comment 2 Remy Suen CLA 2010-09-04 08:39:47 EDT
I'm pretty sure this is dictated by the OS.
Comment 3 Josh O'Dowd CLA 2010-09-05 18:21:57 EDT
(In reply to comment #2)
> I'm pretty sure this is dictated by the OS.

Odd that MULTI select style allows 0-many selections and SINGLE select style allows exactly 1 selection, but not 0.  Interesting.
Comment 4 Josh O'Dowd CLA 2010-09-05 18:24:49 EDT
You guys can close this if it is not something that precipitates a need for change.  Thanks for your time.

-Josh
Comment 5 Felipe Heidrich CLA 2010-09-07 09:52:53 EDT
Platform behaviour. Closing as Wont fix.

You can see this behaviour on Windows Explorer (try on My network place, where rename is not enabled)