Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / First Aid / November 2006

Tip: Looking for answers? Try searching our database.

CheckBox in a ListCellRenderer

Thread view: 
Luc Van Bogaert - 29 Nov 2006 18:45 GMT
Hi,

I've implemented a ListCellRenderer panel, that contains among other
components a JCheckBox to visualise the 'selected' state of the
elements in a JList object. I'm wondering if there is a way to
directly change the selection state of the checkbox using the mouse.
As the list is implemented now, a mouse click just selects the list
element itself, but I've found no way yet to directly change the state
of the checkbox. I could add a MouseListener to the list and process a
double click to alter the checkbox, but I'm wondering if there is a
better way using a single mouseclick.

Thanks in advance.

Signature

Luc Van Bogaert

Michael Dunn - 30 Nov 2006 04:17 GMT
> Hi,
>
[quoted text clipped - 7 lines]
> double click to alter the checkbox, but I'm wondering if there is a
> better way using a single mouseclick.

http://www.objects.com.au/java/examples/swing/CheckBoxList2.do
Luc Van Bogaert - 30 Nov 2006 14:56 GMT
> http://www.objects.com.au/java/examples/swing/CheckBoxList2.do

Thanks!

Signature

Luc Van Bogaert



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2010 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.