1

I would like to bind 3 toggle button with my domain object. The 3 toggle should be mutually exclusive, if one of the 3 boolean property in my domain object is true, then the toggle corresponding is selected and the other 2 are unselected.

I have a solution based on RadioButtonAdapter, but i find it strange. So I was wondering if there was another solution...

Jeffrey Blake
  • 9,659
  • 6
  • 43
  • 65
xtrem06
  • 253
  • 1
  • 3
  • 10
  • 1
    what have you tried so far and what exactly is the problem? AFAIR, goodies comes with example code which demonstrates how to reach your goal – kleopatra Oct 27 '11 at 09:37
  • I haven't found the exemple code in the .zip (version 2.5) i downloaded but i could find some basic exemple on the web. So i have a solution for my problem that use RadioButtonAdapter. I was just wondering if there was another way of doing it. – xtrem06 Oct 27 '11 at 09:46
  • what's wrong with the solution you found? – kleopatra Oct 27 '11 at 09:50
  • It's not using booleans that i have in my model, but an enum value, that contains the three state, one for each button. I thought that there was solution based on booleans...Using RadioButtonAdapter seems to be a turn around. And i want to use JGoodies the way it has to be used. – xtrem06 Oct 27 '11 at 10:04

1 Answers1

0

Try putting your radio-buttons in a ButtonGroup. Then bind your buttons as usual with Bindings.bind.

jackrabbit
  • 5,525
  • 1
  • 27
  • 38