Issue #590 Fixed GFE colorbar when changing parms after setting up collaboration session. Needed to move adding of listeners to initInternal and not the constructor so recycling readds them after dispose removes them

Change-Id: Ieb5fc7786682b5b442deccf4a5292374a4a7de47

Former-commit-id: 81b6158c40 [formerly ab871d218b] [formerly 81b6158c40 [formerly ab871d218b] [formerly 61e0ea0516 [formerly c0d7f68bed2b141240d2e2a695c8439f7a4ffa67]]]
Former-commit-id: 61e0ea0516
Former-commit-id: 460a1179af [formerly 66a60a7b7b]
Former-commit-id: 77aef2db41
This commit is contained in:
Max Schenkelberg 2012-06-20 15:32:27 -05:00
parent 48d821f5f8
commit 379ca48057

View file

@ -289,17 +289,10 @@ public class GFEColorbarResource extends
}.run(); }.run();
} }
@SuppressWarnings("unchecked")
public GFEColorbarResource(DataManager dManager) { public GFEColorbarResource(DataManager dManager) {
super(new GFEResourceData(), new LoadProperties()); super(new GFEResourceData(), new LoadProperties());
this.dManager = dManager; this.dManager = dManager;
fittedParms = new HashSet<ParmID>(); fittedParms = new HashSet<ParmID>();
// this.lastIndex = -1;
dManager.getSpatialDisplayManager().addDisplayModeChangedListener(this);
dManager.getParmManager().addDisplayedParmListChangedListener(this);
Message.registerInterest(this, ShowQuickViewDataMsg.class);
} }
/* /*
@ -353,8 +346,14 @@ public class GFEColorbarResource extends
* @seecom.raytheon.viz.core.rsc.IVizResource#init(com.raytheon.viz.core. * @seecom.raytheon.viz.core.rsc.IVizResource#init(com.raytheon.viz.core.
* IGraphicsTarget) * IGraphicsTarget)
*/ */
@SuppressWarnings("unchecked")
@Override @Override
protected void initInternal(IGraphicsTarget target) throws VizException { protected void initInternal(IGraphicsTarget target) throws VizException {
dManager.getSpatialDisplayManager().addDisplayModeChangedListener(this);
dManager.getParmManager().addDisplayedParmListChangedListener(this);
Message.registerInterest(this, ShowQuickViewDataMsg.class);
colorbarScaleFont = GFEFonts.makeGFEIFont(target, "ColorBarScale_font", colorbarScaleFont = GFEFonts.makeGFEIFont(target, "ColorBarScale_font",
1); 1);
colorbarWxLabelFont = GFEFonts.makeGFEIFont(target, colorbarWxLabelFont = GFEFonts.makeGFEIFont(target,