git-svn-id: http://svn.3splooges.com/romraider-arch/trunk@604 d2e2e1cd-ba16-0410-be16-b7c4453c7c2d

This commit is contained in:
Tgui 2007-04-04 04:05:40 +00:00
parent b027d0705b
commit b50b6a29ac
6 changed files with 25 additions and 9 deletions

View File

@ -120,6 +120,7 @@ public class NewGUI extends JFrame implements ActionListener, TreeSelectionListe
} }
this.jMenuBar.add(this.tuningEntitiesJMenu); this.jMenuBar.add(this.tuningEntitiesJMenu);
this.jMenuBar.setBackground(new Color(236, 233, 216));
this.setLayout(new BorderLayout()); this.setLayout(new BorderLayout());
this.setJMenuBar(this.jMenuBar); this.setJMenuBar(this.jMenuBar);
@ -132,6 +133,7 @@ public class NewGUI extends JFrame implements ActionListener, TreeSelectionListe
splitPane.setDividerLocation(200); splitPane.setDividerLocation(200);
splitPane.setLeftComponent(leftJTree); splitPane.setLeftComponent(leftJTree);
splitPane.setRightComponent(rightDesktopPane); splitPane.setRightComponent(rightDesktopPane);
splitPane.setDividerSize(5);
// Setup main JPanel // Setup main JPanel
@ -219,8 +221,9 @@ public class NewGUI extends JFrame implements ActionListener, TreeSelectionListe
} }
public void setNewToolBar(JToolBar theToolBar) { public void setNewToolBar(JToolBar theToolBar) {
// Ensure proper color
theToolBar.setBackground(new Color(236, 233, 216));
this.add(theToolBar, BorderLayout.NORTH); this.add(theToolBar, BorderLayout.NORTH);
} }

View File

@ -79,6 +79,7 @@ public class EInternalFrame extends JInternalFrame implements InternalFrameListe
excelCopy = new ClipBoardCopy(eTable); excelCopy = new ClipBoardCopy(eTable);
JTable headerColumn = new JTable(tableModel, rowHeaderModel); JTable headerColumn = new JTable(tableModel, rowHeaderModel);
headerColumn.setBackground(new Color(236, 233, 216));
eTable.createDefaultColumnsFromModel(); eTable.createDefaultColumnsFromModel();
headerColumn.createDefaultColumnsFromModel(); headerColumn.createDefaultColumnsFromModel();
eTable.setSelectionModel(headerColumn.getSelectionModel()); eTable.setSelectionModel(headerColumn.getSelectionModel());

View File

@ -15,13 +15,13 @@ import javax.swing.JOptionPane;
public class ETableMenuBar extends JMenuBar implements ActionListener{ public class ETableMenuBar extends JMenuBar implements ActionListener{
private JMenu tableMenu = new JMenu("Table"); private JMenu tableMenu = new JMenu("File");
private JMenuItem saveItem = new JMenuItem("Save");
private JMenuItem undoItem = new JMenuItem("Undo");
private JMenuItem closeItem = new JMenuItem("Close"); private JMenuItem closeItem = new JMenuItem("Close");
private JMenu editMenu = new JMenu("Edit"); private JMenu editMenu = new JMenu("Edit");
private JMenuItem saveItem = new JMenuItem("Save");
private JMenuItem undoItem = new JMenuItem("Undo");
private JMenuItem copyTable = new JMenuItem("Copy Table"); private JMenuItem copyTable = new JMenuItem("Copy Table");
private JMenuItem copySelection = new JMenuItem("Copy Selection"); private JMenuItem copySelection = new JMenuItem("Copy Selection");
private JMenuItem paste = new JMenuItem("Paste Table Data"); private JMenuItem paste = new JMenuItem("Paste Table Data");
@ -37,8 +37,6 @@ public class ETableMenuBar extends JMenuBar implements ActionListener{
this.saveItem.addActionListener(this); this.saveItem.addActionListener(this);
this.undoItem.addActionListener(this); this.undoItem.addActionListener(this);
this.closeItem.addActionListener(this); this.closeItem.addActionListener(this);
this.tableMenu.add(saveItem);
this.tableMenu.add(undoItem);
this.tableMenu.add(closeItem); this.tableMenu.add(closeItem);
this.add(this.tableMenu); this.add(this.tableMenu);
@ -47,6 +45,9 @@ public class ETableMenuBar extends JMenuBar implements ActionListener{
this.copySelection.addActionListener(this); this.copySelection.addActionListener(this);
this.copyTable.addActionListener(this); this.copyTable.addActionListener(this);
this.paste.addActionListener(this); this.paste.addActionListener(this);
this.editMenu.add(saveItem);
this.editMenu.add(undoItem);
this.editMenu.addSeparator();
this.editMenu.add(this.copySelection); this.editMenu.add(this.copySelection);
this.editMenu.add(this.copyTable); this.editMenu.add(this.copyTable);
this.editMenu.addSeparator(); this.editMenu.addSeparator();

View File

@ -26,10 +26,11 @@ public class ETableRowLabel extends AbstractTableModel{
return arg0; return arg0;
} }
return this.labels[arg1]; return this.labels[arg0];
} }
public String getColumnName(int col){ public String getColumnName(int col){
if(this.labels == null){ if(this.labels == null){
return counter++ + ""; return counter++ + "";
} }

View File

@ -379,7 +379,7 @@ public class UtecMapData {
public void populateMapComment(){ public void populateMapComment(){
int start = rawMapData.indexOf("Map Comments:-[")+15; int start = rawMapData.indexOf("Map Comments:-[")+15;
int stop = rawMapData.indexOf("Fuel Map") - 3; int stop = rawMapData.indexOf("Fuel Map") - 2;
this.mapComment = rawMapData.substring(start, stop); this.mapComment = rawMapData.substring(start, stop);
System.out.println("Map comment:"+mapComment+":"); System.out.println("Map comment:"+mapComment+":");
} }
@ -387,7 +387,7 @@ public class UtecMapData {
public void populateMapName(){ public void populateMapName(){
System.out.println("Populating map name."); System.out.println("Populating map name.");
int start = rawMapData.indexOf("Map Name:-[")+11; int start = rawMapData.indexOf("Map Name:-[")+11;
int stop = rawMapData.indexOf("Map Comments") - 3; int stop = rawMapData.indexOf("Map Comments") - 2;
System.out.println("Start:"+start); System.out.println("Start:"+start);
System.out.println("Stop:"+stop); System.out.println("Stop:"+stop);

View File

@ -0,0 +1,10 @@
package enginuity.logger.utec.mapData;
public class testMapChecksum {
public static void main(String[] args){
System.out.println("Testing checksum");
UtecMapData testMapData = new UtecMapData();
testMapData.importFileData("c:\\stistage1olf.TXT");
}
}