Community
Participate
Working Groups
ButtonObservableValue doesn't diff the old and new values to determine if a change event should be fired. The following test will fail but shouldn't. public void testFiresEventsWhenChanged() throws Exception { Shell shell = new Shell(); Button button = new Button(shell, SWT.CHECK); ButtonObservableValue observableValue = new ButtonObservableValue(button); ValueChangeEventTracker tracker = new ValueChangeEventTracker(); observableValue.addValueChangeListener(tracker); assertEquals(Boolean.FALSE, observableValue.getValue()); button.notifyListeners(SWT.Selection, null); assertEquals(0, tracker.count); //fails with count == 1 }
I'm finding others that exhibit this behavior as well. I'm updating the summary to be more generic so that we don't have to log a bug for each. Observables: * ButtonObservableValue * JavaBeanObservableValue
Add to the list: * CComboObservableValue (Text) * CComboObservableValue (Selection) * ComboObservableValue (Text) * ComboObservableValue (Selection) * CLabelObservableValue (Text)
Add to the list: * ScaleObservableValue (Minimum) * ScaleObservableValue (Maximum) * ScaleObservableValue (Selection) * SpinnerObservableValue (Minimum) * SpinnerObservableValue (Selection) * TableSingleSelectionObservableValue * TextEditableObservableValue (doesn't fire any change events - bug 197408)
FIXED > 20070908. This was fixed with the merge to HEAD of bug 182059.