Community
Participate
Working Groups
Due to a hack introduced to fix Bug 271762 we have the following undesired behavior: if the toggle-button-ridget is output-only and state change via setSelected(boolean) will be blocked. Output-only should only block changes from the user (i.e. UI) and not interfere with programmatic API calls. Fixing. Note: the fix slightly modifies the semantics of setSelected(...) but since the broken/unexpected behavior was not specified in the javadoc, I consider it an implementation detail. Test case: public void testSetSelectedOnOutputOnlyCheckboxChangesState() { final IToggleButtonRidget ridget = getRidget(); ridget.setOutputOnly(false); ridget.setSelected(false); assertFalse(ridget.isSelected()); ridget.setOutputOnly(true); ridget.setSelected(true); assertTrue(ridget.isSelected()); // <--- this fails, it should be true }
Resolved in HEAD.