How can I prevent ListBox from selecting an item when I right-click it?
Posted
by chaiguy
on Stack Overflow
See other posts from Stack Overflow
or by chaiguy
Published on 2010-06-09T23:30:50Z
Indexed on
2010/06/09
23:42 UTC
Read the original article
Hit count: 280
The tricky part is that each item has a ContextMenu
that I still want to open when it is right-clicked (I just don't want it selecting it).
In fact, if it makes things any easier, I don't want any automatic selection at all, so if there's some way I can disable it entirely that would be just fine.
I'm thinking of just switching to an ItemsControl
actually, so long as I can get virtualization and scrolling to work with it.
© Stack Overflow or respective owner