Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » NatTable » Selection not working with disabled sorting
Selection not working with disabled sorting [message #1065560] Wed, 26 June 2013 13:59 Go to next message
Testr t is currently offline Testr tFriend
Messages: 93
Registered: April 2013
Member
Hi,

I am using tree grid in my application. I have enabled sorting on specific columns using the "SORT" and "NOSORT" labels and assigning DefaultComparator and NullComparator for those lables. This works pefectly fine except that I am not able to click on the column header on the columns that does not have sorting. I would like the option to click on the column header so that the entire column can be selected(I have some functionalities to apply on selected cells and this would make it easier). But since the sorting is disabled, clicking the cell there does not have any effect and even selection does not work. The same behavior can be seen on the SortableGridExample on the Ask Column.
Re: Selection not working with disabled sorting [message #1065583 is a reply to message #1065560] Wed, 26 June 2013 15:04 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2902
Registered: July 2012
Senior Member
Well, looking at the example you mentioned, there is also no column selection performed on sorting one of the other columns. This is because you configure that the SortColumnAction should be performed on single click a column header cell (this is done in the SingleClickSortConfiguration).

If you want to combine sorting AND column selection on single click you potentially need to implement your own IMouseAction that does both, calling the SortColumnCommand AND the ViewportSelectColumnCommand and configure it as first single click binding instead using the SingleClickSortConfiguration
Re: Selection not working with disabled sorting [message #1065609 is a reply to message #1065583] Wed, 26 June 2013 16:15 Go to previous messageGo to next message
Testr t is currently offline Testr tFriend
Messages: 93
Registered: April 2013
Member
Okay. I understand that the SingleClickSortConfiguration removes the selection binding. Is it possible to configure SingleClickConfiguration only for specific columns, i.e only for the columns that have sorting enabled? And for other columns where I have disabled sorting(through labels and NullComparator), I do not want the SingleClickConfiguration. I do not want to combine them. In the columns where I have Sorting enabled I do not want the entire column selection functionality.
Re: Selection not working with disabled sorting [message #1065704 is a reply to message #1065609] Thu, 27 June 2013 08:21 Go to previous message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2902
Registered: July 2012
Senior Member
Then implement a custom configuration that performs single click in case of the SORT label and column selection in case there is NOSORT.
Previous Topic:Sorting in tree grid
Next Topic:Filter option in tree grid
Goto Forum:
  


Current Time: Fri Apr 26 10:55:03 GMT 2024

Powered by FUDForum. Page generated in 1.25130 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top