Explorar o código

ungenutzte sachen entfernt

Kevin Trometer %!s(int64=8) %!d(string=hai) anos
pai
achega
c1625ab070
Modificáronse 1 ficheiros con 52 adicións e 4 borrados
  1. 52 4
      src/ui/view/GUI.java

+ 52 - 4
src/ui/view/GUI.java

@@ -27,11 +27,9 @@ import javax.swing.DefaultComboBoxModel;
 import javax.swing.ImageIcon;
 import javax.swing.InputMap;
 import javax.swing.JButton;
-import javax.swing.JCheckBoxMenuItem;
 import javax.swing.JComboBox;
 import javax.swing.JComponent;
 import javax.swing.JDialog;
-import javax.swing.JEditorPane;
 import javax.swing.JFileChooser;
 import javax.swing.JFrame;
 import javax.swing.JLabel;
@@ -109,7 +107,6 @@ public class GUI<E> implements CategoryListener {
 	private String holonEleNamesDisplayed = "None ";
 	HashMap<Integer, ArrayList<HolonElement>> eleToDelete = new HashMap<Integer, ArrayList<HolonElement>>();
 	private final JTree tree = new JTree();
-	private final JEditorPane dtrpnHereWillBe = new JEditorPane();
 	/******************************************
 	 ************* Right Container*************
 	 ******************************************/
@@ -135,6 +132,11 @@ public class GUI<E> implements CategoryListener {
 	// Table for Properties --> Cell with (0,1) is editable by CpsObjt and
 	// Cell(3,1) is editable by Edges
 	private JTable tableProperties = new JTable() {
+		/**
+		 * 
+		 */
+		private static final long serialVersionUID = 1L;
+
 		@Override
 		public TableCellRenderer getCellRenderer(int row, int column) {
 			if (getValueAt(row, column) instanceof Boolean) {
@@ -231,6 +233,7 @@ public class GUI<E> implements CategoryListener {
 		simMenu = new SimulationMenu(model, control);
 		initialize();
 		updateCategories(model.getCategories());
+
 	}
 
 	/**
@@ -278,6 +281,11 @@ public class GUI<E> implements CategoryListener {
 		inputMap.put(KeyStroke.getKeyStroke("control Z"), cntrlZDown);
 		actionMap.put(cntrlZDown, new AbstractAction() {
 
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				try {
@@ -310,6 +318,11 @@ public class GUI<E> implements CategoryListener {
 		inputMap.put(KeyStroke.getKeyStroke("control Y"), cntrlYDown);
 		actionMap.put(cntrlYDown, new AbstractAction() {
 
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				try {
@@ -341,6 +354,11 @@ public class GUI<E> implements CategoryListener {
 		String cntrlADown = "controlA";
 		inputMap.put(KeyStroke.getKeyStroke("control A"), cntrlADown);
 		actionMap.put(cntrlADown, new AbstractAction() {
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				model.getSelectedCpsObjects().clear();
@@ -354,6 +372,11 @@ public class GUI<E> implements CategoryListener {
 		String delDown = "delete";
 		inputMap.put(KeyStroke.getKeyStroke(KeyEvent.VK_DELETE, 0, false), delDown);
 		actionMap.put(delDown, new AbstractAction() {
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				for (CpsObject cps : model.getSelectedCpsObjects()) {
@@ -378,6 +401,11 @@ public class GUI<E> implements CategoryListener {
 		inputMap.put(KeyStroke.getKeyStroke("control F"), cntrlFDown);
 		actionMap.put(cntrlFDown, new AbstractAction() {
 
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				searchPopUp dialog = new searchPopUp(controller, canvas);
@@ -390,6 +418,11 @@ public class GUI<E> implements CategoryListener {
 		inputMap.put(KeyStroke.getKeyStroke("control C"), cntrlCDown);
 		actionMap.put(cntrlCDown, new AbstractAction() {
 
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				if (!model.getSelectedCpsObjects().isEmpty()) {
@@ -405,6 +438,11 @@ public class GUI<E> implements CategoryListener {
 		inputMap.put(KeyStroke.getKeyStroke("control V"), cntrlVDown);
 		actionMap.put(cntrlVDown, new AbstractAction() {
 
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				controller.pasteObjects(canvas.getMousePosition());
@@ -416,6 +454,11 @@ public class GUI<E> implements CategoryListener {
 		inputMap.put(KeyStroke.getKeyStroke("control X"), cntrlXDown);
 		actionMap.put(cntrlXDown, new AbstractAction() {
 
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			@Override
 			public void actionPerformed(ActionEvent e) {
 				if (!model.getSelectedCpsObjects().isEmpty()) {
@@ -962,7 +1005,7 @@ public class GUI<E> implements CategoryListener {
 					DefaultMutableTreeNode selectedNode = (DefaultMutableTreeNode) tree
 							.getPathForLocation(e.getX(), e.getY()).getLastPathComponent();
 					if (selectedNode.getLevel() == 2) {
-						CpsObject selected = controller.searchCategoryObject(selectedNode.getParent().toString(),
+						controller.searchCategoryObject(selectedNode.getParent().toString(),
 								selectedNode.toString());
 						deleteRows(tableModelHolonElementSingle);
 						deleteRows(tableModelHolonElementMulti);
@@ -1514,6 +1557,11 @@ public class GUI<E> implements CategoryListener {
 	 */
 	public void updateCategories(final ArrayList<Category> categories) {
 		tree.setModel(new DefaultTreeModel(new DefaultMutableTreeNode("Categories") {
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1L;
+
 			{
 				DefaultMutableTreeNode node_1;
 				for (Category c : categories) {