public void show()

in taverna-external-tool-activity-ui/src/main/java/org/apache/taverna/activities/externaltool/manager/ssh/SshInvocationMechanismEditor.java [69:135]


	public void show(ExternalToolSshInvocationMechanism invocationMechanism) {
		mechanism = invocationMechanism;
		this.removeAll();
		inputGridy = 1;
		final JPanel innerPanel = new JPanel(new GridBagLayout());

		final GridBagConstraints inputConstraint = new GridBagConstraints();
		inputConstraint.anchor = GridBagConstraints.FIRST_LINE_START;
		inputConstraint.gridx = 0;
		inputConstraint.gridy = 0;
		inputConstraint.weightx = 0.1;
		inputConstraint.fill = GridBagConstraints.BOTH;

		inputConstraint.gridx = 0;
			nodeViewers.clear();
			for (SshNode node : invocationMechanism.getNodes()) {
				ExternalToolSshNodeViewer nodeViewer = new ExternalToolSshNodeViewer(node);
				addNodeViewer(this, innerPanel, nodeViewer);
			}

		this.setLayout(new GridBagLayout());
		GridBagConstraints outerPanelConstraint = new GridBagConstraints();
		outerPanelConstraint.gridx = 0;
		outerPanelConstraint.gridy = 0;
		outerPanelConstraint.weightx = 0.1;
		outerPanelConstraint.weighty = 0.1;
		outerPanelConstraint.fill = GridBagConstraints.BOTH;
		this.add(new JScrollPane(innerPanel),
				outerPanelConstraint);
		outerPanelConstraint.weighty = 0;
		final JButton addHostButton = new DeselectingButton("Add host",
				new AbstractAction() {
			public void actionPerformed(ActionEvent e) {

				ExternalToolSshNodeViewer newViewer = new ExternalToolSshNodeViewer();

					addNodeViewer(SshInvocationMechanismEditor.this, innerPanel, newViewer);
					innerPanel.revalidate();
					innerPanel.repaint();
			}

		});
		JPanel buttonPanel = new JPanel();
		buttonPanel.setLayout(new GridBagLayout());

		JPanel filler = new JPanel();
		outerPanelConstraint.weightx = 0.1;
		outerPanelConstraint.weighty = 0;
		outerPanelConstraint.gridx = 0;
		outerPanelConstraint.gridy = 0;

		buttonPanel.add(filler, outerPanelConstraint);

		outerPanelConstraint.weightx = 0;
		outerPanelConstraint.weighty = 0;
		outerPanelConstraint.gridx = 1;
		outerPanelConstraint.gridy = 0;

		buttonPanel.add(addHostButton, outerPanelConstraint);

		outerPanelConstraint.weightx = 0;
		outerPanelConstraint.weighty = 0;
		outerPanelConstraint.gridx = 0;
		outerPanelConstraint.gridy = 1;
		outerPanelConstraint.fill = GridBagConstraints.BOTH;
		this.add(buttonPanel, outerPanelConstraint);
	}