Device device = this.devConf.classForDevice(s); if (s != null) { PatchEdit.appConfig.addDevice(device); String info = device.getInfoText(); if (info != null && info.length() > 0) { JTextArea jta = new JTextArea(info, 15, 40); jta.setEditable(false); jta.setLineWrap(true); jta.setWrapStyleWord(true); jta.setCaretPosition(0); JScrollPane jasp = new JScrollPane(jta); JOptionPane.showMessageDialog(null, jasp, "Device Information", JOptionPane.INFORMATION_MESSAGE); }
if (s == null) return;  Device device = PatchEdit.devConfig.classForDevice(s); PatchEdit.appConfig.addDevice(device);  String info = device.getInfoText(); if (info != null && info.length() > 0) { JTextArea jta = new JTextArea(info, 15, 40); jta.setEditable(false); jta.setLineWrap(true); jta.setWrapStyleWord(true); jta.setCaretPosition(0); JScrollPane jasp = new JScrollPane(jta); JOptionPane.showMessageDialog(null, jasp, "Device Information", JOptionPane.INFORMATION_MESSAGE);
    void OKPressed() {        this.setVisible(false);        String s = (String) AvailableDeviceList.getSelectedValue();	Device device = this.devConf.classForDevice(s);	if (s != null) {	    PatchEdit.appConfig.addDevice(device);	    String info = device.getInfoText();	    if (info != null && info.length() > 0) {		JTextArea jta = new JTextArea(info, 15, 40);		jta.setEditable(false);		jta.setLineWrap(true);		jta.setWrapStyleWord(true);		jta.setCaretPosition(0);		JScrollPane jasp = new JScrollPane(jta);  		JOptionPane.showMessageDialog(null, jasp,					      "Device Information",  					      JOptionPane.INFORMATION_MESSAGE);	    }	}    }