setEnabled(isConnectionSelected());
}
public void actionPerformed(final ActionEvent e)
{
final IDatabaseConnection existingConnection = (IDatabaseConnection) dataSourceList.getSelectedValue();
try
{
final Window parentWindow = LibSwingUtil.getWindowAncestor(ConnectionEditorPanel.this);
final XulDatabaseDialog connectionDialog = new XulDatabaseDialog(parentWindow);
final IDatabaseConnection connectionDefinition = connectionDialog.open(existingConnection);
// See if the edit completed...
if (connectionDefinition != null)
{
dialogModel.updateDatasourceById(existingConnection.getId(), connectionDefinition);