O'Reilly logo

Java™ ME Game Programming, Second Edition by Ph.D. Martin J. Wells, Ph.D. John P. Flynt

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

ChoiceGroup

The ChoiceGroup class provides a way to group a list of selections together so that when you choose one of them, the message you generate can be retrieved using an index that identifies the choice within the group of choices. In many ways, the ChoiceGroup class resembles the List class. As the ComedyChoiceGroup class illustrates, when you create a ChoiceGroup object, one ready option is to make it so that you select one item at a time. Clicking one radio button, in other words, deactivates other selections. This list is created using the EXCLUSIVE property, which is provided by the ChoiceGroup class definition. In addition to single selections, you can also make multiple selections. To set this option, you define the ChoiceGroup

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required