Notifying other checkboxes to toggle the state within an Action

Hello,

I created an action that toggles visibility of one dialog. There is a JCheckBoxItem in the menu and JToogleButton on the toolbar. Both with this action deployed (with setAction() method).

When user click on the menu item checkbox it do not toggle the checkbox on the toobar and vice versa. I need some mechanism to "connect" the checkboxes with same action to set their values synchronously.

What mechanisms or interfaces to do this?

[465 byte] By [Lukas_Zapletala] at [2007-10-2 14:14:26]
# 1
toggleButton.setModel(checkBoxItem.getModel());
Michael_Dunna at 2007-7-13 12:29:34 > top of Java-index,Security,Event Handling...