Bug 255734 [DataBinding] DecoratingObservable should self-dispose when the decorated observable is disposed
DecoratingObservable should dispose itself in response to the disposal of its decorated observable. One thing we'll have to address is that all existing observables may call firstListenerAdded() / lastListenerRemoved() in response to an addDisposeListener() / removeDisposeListener() call. We should try to eliminate this case to avoid hooking listeners when all we're interested in is disposal.
tests/org.eclipse.jface.tests.databinding/src/org/eclipse/jface/tests/databinding/BindingTestSuite.java
/*******************************************************************************
 * Copyright (c) 2005-2008 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *     Brad Reynolds - bugs 137877, 152543, 152540, 116920, 164247, 164653,
 *                     159768, 170848, 147515
 *     Bob Smith - bug 198880
 *     Ashley Cambrell - bugs 198903, 198904
 *     Matthew Hall - bugs 210115, 212468, 212223, 206839, 208858, 208322,
 *                    212518, 215531, 221351, 184830, 213145, 218269, 239015,
 *                    237703, 237718, 222289, 247394, 233306, 247647, 254524,
 *                    246103, 249992, 256150, 256543, 262269, 175735, 262946
 *     Ovidio Mallo - bug 237163, bug 235195