use of cbit.vcell.client.data.ODEDataInterface in project vcell by virtualcell.
the class ODESolverPlotSpecificationPanel method initConnections.
/**
* Initializes connections
* @exception java.lang.Exception The exception description.
*/
@SuppressWarnings({ "serial", "unchecked" })
private void initConnections() throws java.lang.Exception {
// user code begin {1}
// user code end
getFilterPanel().addPropertyChangeListener(ivjEventHandler);
getYAxisChoice().addListSelectionListener(ivjEventHandler);
this.addPropertyChangeListener(ivjEventHandler);
getXAxisComboBox_frm().addItemListener(ivjEventHandler);
getLogSensCheckbox().addActionListener(ivjEventHandler);
getSensitivityParameterSlider().addChangeListener(ivjEventHandler);
connPtoP1SetTarget();
connPtoP3SetTarget();
getYAxisChoice().setCellRenderer(new DefaultListCellRenderer() {
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
super.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
ODEDataInterface mdi = getMyDataInterface();
if (mdi == null) {
return this;
}
String varName = (String) value;
ColumnDescription cd = null;
try {
cd = mdi.getColumnDescription(varName);
} catch (ObjectNotFoundException e) {
e.printStackTrace();
}
if (cd instanceof FunctionColumnDescription && ((FunctionColumnDescription) cd).getIsUserDefined()) {
if (function_icon == null) {
function_icon = new ImageIcon(getClass().getResource("/icons/function_icon.png"));
}
setIcon(function_icon);
}
if (mdi.getDataSymbolMetadataResolver() != null && mdi.getDataSymbolMetadataResolver().getDataSymbolMetadata(varName) != null) {
DataSymbolMetadata dsm = mdi.getDataSymbolMetadataResolver().getDataSymbolMetadata(varName);
String tooltipString = dsm.tooltipString;
if (tooltipString == null) {
tooltipString = varName;
}
setToolTipText(tooltipString);
}
return this;
}
});
}
use of cbit.vcell.client.data.ODEDataInterface in project vcell by virtualcell.
the class ODESolverPlotSpecificationPanel method setMyDataInterface.
/**
* Sets the odeSolverResultSet property (cbit.vcell.solver.ode.ODESolverResultSet) value.
* @param odeSolverResultSet The new value for the property.
* @see #getOdeSolverResultSet
*/
public void setMyDataInterface(ODEDataInterface newMyDataInterface) {
ODEDataInterface oldValue = oDEDataInterface;
/* Stop listening for events from the current object */
if (oldValue != null) {
oldValue.removePropertyChangeListener(ivjEventHandler);
}
oDEDataInterface = newMyDataInterface;
if (oDEDataInterface != null) {
oDEDataInterface.addPropertyChangeListener(ivjEventHandler);
}
firePropertyChange(ODESOLVERRESULTSET_CHANGED, oldValue, oDEDataInterface);
}
Aggregations