DropdownMenu selects entire column

Tags: #<Tag:0x00007f8b18441a38>

Using 7.0.3, when I click on the dropdownMenu button in the header row, the entire column is selected. This appears to be by design. I want to prevent this selection when the user clicks the dropdownMenu button.

In attempting to work around the issue, I found (2) things that thought would work but don’t:

  1. Add hook for afterDropdownMenuShow. Only the dropdownOptions is passed, and since the ClickEvent is not passed this means that I can’t stopPropagation().
  2. Get eventManager and addEventListener… unfortunately the select fires before my listener, so stopping it does nothing.

What is the proper way to prevent an entire column from being selected when you click the dropdownMenu button in the header row?

Sorry @SteveHartzog but it doesn’t seem to be possible via API.
When you deselect the cells https://jsfiddle.net/handsoncode/q3ux4yjd/ you won’t get the options available.

I found a way to do it. https://jsfiddle.net/shartzog/b6ws27ca/

It basically just runs stopImmediatePropagation() and saves the column index for usage in your method implementation.

However, you have to reimplement the default behavior for menu items (e.g. add_column).

Thank you @aleksandra_budnik for the example, I used it heavily to arrive at my solution - which works nicely in our application.

Great. I’m really glad to see this working.