Skip to main content

Enhance ButtonGroup Somewhat

No replies
mgrev
Offline
Joined: 2003-08-12

BG is a simple way to group toggle buttons. Though it could with simple means be made better.

1) Add a vararg constructor:

public ButtonGroup(AbstractButton... buttons)

2) Make it possible to listen on the button group for changes.

3) Add a 'initially selected' constructor

public ButtonGroup(AbstractButton... buttons, AbstractButton selected)

All in the 'make it simpler for newbies campain'

Cheers,
Mikael Grev