Added a license box.
This commit is contained in:
parent
920239493b
commit
fe20aaba18
@ -48,6 +48,7 @@ import javax.swing.event.MenuEvent;
|
||||
import javax.swing.event.MenuListener;
|
||||
|
||||
import eva2.gui.ExtAction;
|
||||
import eva2.gui.HtmlDemo;
|
||||
import eva2.gui.JEFrame;
|
||||
import eva2.gui.JEFrameRegister;
|
||||
import eva2.gui.JExtMenu;
|
||||
@ -75,6 +76,7 @@ import wsi.ra.tool.BasicResourceLoader;
|
||||
*/
|
||||
public class EvAClient implements RemoteStateListener, Serializable {
|
||||
public static final String EVA_PROPERTY_FILE = "resources/EvA2.props";
|
||||
public static final String licenseFile = "lgpl-3.0.txt";
|
||||
private static Properties EVA_PROPERTIES;
|
||||
public static final String iconLocation = "resources/images/icon4.gif";
|
||||
private static final String splashLocation = "resources/images/splashScreen2.png";
|
||||
@ -114,6 +116,7 @@ public class EvAClient implements RemoteStateListener, Serializable {
|
||||
// private ArrayList m_ModuleAdapterList = new ArrayList();
|
||||
// About:
|
||||
private ExtAction m_actAbout;
|
||||
private ExtAction m_actLicense;
|
||||
|
||||
// private JPanel m_panelTool;
|
||||
// private FrameCloseListener m_frameCloseListener;
|
||||
@ -301,6 +304,13 @@ public class EvAClient implements RemoteStateListener, Serializable {
|
||||
showAboutDialog();
|
||||
}
|
||||
};
|
||||
m_actLicense = new ExtAction("&License...", "View License",
|
||||
KeyStroke.getKeyStroke(KeyEvent.VK_L, Event.CTRL_MASK)) {
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
logMessage(e.getActionCommand());
|
||||
showLicense();
|
||||
}
|
||||
};
|
||||
m_actHost = new ExtAction("&List of all servers", "All servers in list",
|
||||
KeyStroke.getKeyStroke(KeyEvent.VK_A, Event.CTRL_MASK)) {
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
@ -461,6 +471,7 @@ public class EvAClient implements RemoteStateListener, Serializable {
|
||||
////////////////////////////////////////////////////////////////
|
||||
m_mnuAbout = new JExtMenu("&About");
|
||||
m_mnuAbout.add(m_actAbout);
|
||||
m_mnuAbout.add(m_actLicense);
|
||||
//////////////////////////////////////////////////////////////
|
||||
// m_barMenu.add(m_Desktop.getWindowMenu());
|
||||
|
||||
@ -663,6 +674,12 @@ public class EvAClient implements RemoteStateListener, Serializable {
|
||||
"\n http://www.ra.cs.uni-tuebingen.de/software/EvA2", infoTitle, 1);
|
||||
}
|
||||
|
||||
private void showLicense() {
|
||||
HtmlDemo temp = new HtmlDemo(licenseFile);
|
||||
temp.show();
|
||||
}
|
||||
|
||||
|
||||
private void showNoHostFoundDialog() {
|
||||
JOptionPane.showMessageDialog(m_Frame.getContentPane(), "No host with running EVASERVER found. Please start one or \nadd the correct address to the properties list.", infoTitle, 1);
|
||||
}
|
||||
|
@ -12,26 +12,24 @@ package eva2.gui;
|
||||
/*==========================================================================*
|
||||
* IMPORTS
|
||||
*==========================================================================*/
|
||||
import java.awt.BorderLayout;
|
||||
import java.awt.Dimension;
|
||||
import java.awt.Toolkit;
|
||||
import java.io.IOException;
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URL;
|
||||
|
||||
import javax.swing.JEditorPane;
|
||||
import javax.swing.JFrame;
|
||||
import javax.swing.JScrollPane;
|
||||
import javax.swing.JViewport;
|
||||
import javax.swing.JEditorPane;
|
||||
import javax.swing.event.HyperlinkListener;
|
||||
import javax.swing.event.HyperlinkEvent;
|
||||
import javax.swing.text.html.HTMLFrameHyperlinkEvent;
|
||||
import javax.swing.event.HyperlinkListener;
|
||||
import javax.swing.text.html.HTMLDocument;
|
||||
import javax.swing.text.html.HTMLFrameHyperlinkEvent;
|
||||
|
||||
import eva2.client.EvAClient;
|
||||
import eva2.tools.EVAHELP;
|
||||
|
||||
import java.awt.Dimension;
|
||||
import java.awt.BorderLayout;
|
||||
import java.io.IOException;
|
||||
import java.applet.*;
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URL;
|
||||
import java.awt.Toolkit;
|
||||
import wsi.ra.tool.BasicResourceLoader;
|
||||
import eva2.client.EvAClient;
|
||||
/**
|
||||
*
|
||||
*/
|
||||
|
@ -125,7 +125,7 @@ public class CrossoverESBLXAlpha implements InterfaceCrossover, java.io.Serializ
|
||||
* @return description
|
||||
*/
|
||||
public String globalInfo() {
|
||||
return "The BLX crossover init the values within the extreme values plus an add. alpha range (BLX-0.0 equals flat crossover).";
|
||||
return "The BLX crossover inits the values within the extreme values plus an additional alpha range (BLX-0.0 equals flat crossover).";
|
||||
}
|
||||
|
||||
/** This method allows you to set the number of crossovers that occur in the
|
||||
|
@ -121,6 +121,6 @@ public class CrossoverESFlat implements InterfaceCrossover, java.io.Serializable
|
||||
* @return description
|
||||
*/
|
||||
public String globalInfo() {
|
||||
return "The flat crossover init the values within the extreme values.";
|
||||
return "The flat crossover inits the values within the extreme values.";
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user