Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » NatTable » Info about applied Filter
Info about applied Filter [message #1218913] Fri, 29 November 2013 08:53 Go to next message
Arjan Kok is currently offline Arjan Kok
Messages: 29
Registered: July 2009
Junior Member
Hi,

I am using the default Nattable filtering (based on glazedlists.filterlist), and it work fine.
Now I would like to implement a feature, that tells the user of the table how many rows were filtered.
Something like this : 4 out of 10.

Does this feature exist? I did not find it in the examples.

Kind Regards,
Arjan Kok.
Re: Info about applied Filter [message #1219014 is a reply to message #1218913] Fri, 29 November 2013 10:50 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk Fauth
Messages: 1214
Registered: July 2012
Senior Member
no such a feature does not exist. Should be easy by asking the underlying list and the filterlist about its size
Re: Info about applied Filter [message #1219149 is a reply to message #1218913] Mon, 02 December 2013 06:45 Go to previous messageGo to next message
Arjan Kok is currently offline Arjan Kok
Messages: 29
Registered: July 2009
Junior Member
Ok, thanks.

I tried to register a listener for the FilterAppliedEvent on the Top Layer (a GridLayer in my case).
However, it does not get called ?!

this.addLayerListener(new ILayerListener() {
public void handleLayerEvent(ILayerEvent event) {
if (event instanceof FilterAppliedEvent) {
System.out.println("filter applied event");
}
}
});


Is this the correct way to get it done?

Kind Regards, Arjan.
Re: Info about applied Filter [message #1219155 is a reply to message #1219149] Mon, 02 December 2013 07:14 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk Fauth
Messages: 1214
Registered: July 2012
Senior Member
This should work. Did you create your own GridLayer? As you are registering by using "this"
Re: Info about applied Filter [message #1219182 is a reply to message #1219155] Mon, 02 December 2013 09:11 Go to previous message
Arjan Kok is currently offline Arjan Kok
Messages: 29
Registered: July 2009
Junior Member
Yes, I created my own grid layer. Strange enough, adding the listener on the table itself seems to work Smile.

Thanks for your quick support.

Kind Regards,
Arjan.
Previous Topic:ComboBoxCellEditor flickering
Next Topic:GlazedListsEventLayer: multi-threading issue
Goto Forum:
  


Current Time: Fri Jul 25 23:15:07 EDT 2014

Powered by FUDForum. Page generated in 0.02083 seconds