🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #9601

Re: hide rows in JTable?

#9601
From: Tor Iver Wilhelmsen
Date: Sun, 05 Mar 2000 00:00
17 lines
1271 bytes
John P. McGrath <JPMcGrath@fast.net> writes:

> Those two are all you need to change if everything is guaranteed to be 
> static.  But if the data can change, the job gets more complicated.  

No, because you change the _model's_ getRowCount() and getValueAt()
methods, not the JTable's.

> But you also need to listen for changes in the underlying table model, 

No, because that's the one you're working in.

> map the unfiltered row numbers to filtered row numbers, and fire table 
> model events with the filtered row numbers.  Of course you will have to 
> ignore events that only describe changes to filtered rows.

You just don't fire them.
Technical Details
Message-ID: <u66v1wyb0.fsf@sds.no>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <38B969F1.FC38DF02@db.erau.edu> <MPG.13236cbbe6eb6d2a9897c7@forums.borland.com> <89qbui$r9s4@bornews.borland.com> <uk8jizsx7.fsf@sds.no> <MPG.132befc0c63e2db9897d9@forums.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,8e0f666ae34fba12
X-Google-Attributes: gid111d45,public
From: Tor Iver Wilhelmsen <tor.wilhelmsen@sds.no>
Subject: Re: hide rows in JTable?
Date: 2000/03/05
Message-ID: <u66v1wyb0.fsf@sds.no>
X-Deja-AN: 593358585
Sender: towi@SDSA1761
References: <38B969F1.FC38DF02@db.erau.edu> <MPG.13236cbbe6eb6d2a9897c7@forums.borland.com> <89qbui$r9s4@bornews.borland.com> <uk8jizsx7.fsf@sds.no> <MPG.132befc0c63e2db9897d9@forums.borland.com>
Organization: Another Netscape Collabra Server User
Newsgroups: borland.public.jbuilder.java.swing