[Bprocessor-commit] gui/src/net/sourceforge/bprocessor/gui GUI.java,1.9,1.10
Status: Pre-Alpha
Brought to you by:
henryml
From: Michael L. <he...@us...> - 2005-11-15 19:01:10
|
Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5148/src/net/sourceforge/bprocessor/gui Modified Files: GUI.java Log Message: - Removed items from the menus - Implemented File -> New to clear the model - Changed layout of main window Index: GUI.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/GUI.java,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** GUI.java 21 Oct 2005 08:42:47 -0000 1.9 --- GUI.java 15 Nov 2005 19:01:02 -0000 1.10 *************** *** 16,19 **** --- 16,20 ---- import net.sourceforge.bprocessor.gui.actions.FileExportActionListener; import net.sourceforge.bprocessor.gui.actions.FileImportActionListener; + import net.sourceforge.bprocessor.gui.actions.FileNewActionListener; import net.sourceforge.bprocessor.gui.actions.FilePropertiesActionListener; import net.sourceforge.bprocessor.gui.actions.ToolsDetachActionListener; *************** *** 56,60 **** /** The middle/right split pane */ ! private JSplitPane splitPaneMiddleRight; /** The splash */ --- 57,61 ---- /** The middle/right split pane */ ! private JSplitPane splitPaneTopDown; /** The splash */ *************** *** 106,111 **** JMenuItem fileNew = new JMenuItem("New"); fileNew.setMnemonic(KeyEvent.VK_N); ! fileNew.setEnabled(false); file.add(fileNew); --- 107,113 ---- JMenuItem fileNew = new JMenuItem("New"); + fileNew.addActionListener(new FileNewActionListener()); fileNew.setMnemonic(KeyEvent.VK_N); ! fileNew.setEnabled(true); file.add(fileNew); *************** *** 208,211 **** --- 210,214 ---- createElement.setMnemonic(KeyEvent.VK_E); createElement.addActionListener(new CreateElementActionListener()); + createElement.setEnabled(false); create.add(createElement); *************** *** 213,216 **** --- 216,220 ---- createPart.setMnemonic(KeyEvent.VK_P); createPart.addActionListener(new CreatePartActionListener()); + createPart.setEnabled(false); create.add(createPart); *************** *** 218,221 **** --- 222,226 ---- createSurface.setMnemonic(KeyEvent.VK_S); createSurface.addActionListener(new CreateSurfaceActionListener()); + createSurface.setEnabled(false); create.add(createSurface); *************** *** 229,238 **** toolsJoin.setMnemonic(KeyEvent.VK_J); toolsJoin.addActionListener(new ToolsJoinActionListener()); ! tools.add(toolsJoin); JMenuItem toolsDetach = new JMenuItem("Detach"); toolsDetach.setMnemonic(KeyEvent.VK_D); toolsDetach.addActionListener(new ToolsDetachActionListener()); ! tools.add(toolsDetach); menu.registerMenu(tools); --- 234,243 ---- toolsJoin.setMnemonic(KeyEvent.VK_J); toolsJoin.addActionListener(new ToolsJoinActionListener()); ! //tools.add(toolsJoin); JMenuItem toolsDetach = new JMenuItem("Detach"); toolsDetach.setMnemonic(KeyEvent.VK_D); toolsDetach.addActionListener(new ToolsDetachActionListener()); ! //tools.add(toolsDetach); menu.registerMenu(tools); *************** *** 279,289 **** */ public void createMainView() { ! splitPaneMiddleRight = new JSplitPane(); ! splitPaneMiddleRight.setLeftComponent(new JPanel()); ! splitPaneMiddleRight.setRightComponent(new JPanel()); splitPaneLeftRight = new JSplitPane(); ! splitPaneLeftRight.setLeftComponent(new JPanel()); ! splitPaneLeftRight.setRightComponent(splitPaneMiddleRight); getContentPane().setLayout(new BorderLayout()); --- 284,295 ---- */ public void createMainView() { ! splitPaneTopDown = new JSplitPane(JSplitPane.VERTICAL_SPLIT); ! splitPaneTopDown.setTopComponent(new JPanel()); ! splitPaneTopDown.setBottomComponent(new JPanel()); ! splitPaneTopDown.setDividerLocation(460); splitPaneLeftRight = new JSplitPane(); ! splitPaneLeftRight.setRightComponent(new JPanel()); ! splitPaneLeftRight.setLeftComponent(splitPaneTopDown); getContentPane().setLayout(new BorderLayout()); *************** *** 308,319 **** public void registerPanel(Component panel, Integer placement) { if (placement.equals(SPLIT_LEFT)) { ! splitPaneLeftRight.remove(1); ! splitPaneLeftRight.setLeftComponent(new JScrollPane(panel)); } else if (placement.equals(SPLIT_MIDDLE)) { ! splitPaneMiddleRight.remove(1); ! splitPaneMiddleRight.setLeftComponent(panel); } else { ! splitPaneMiddleRight.remove(2); ! splitPaneMiddleRight.setRightComponent(new JScrollPane(panel)); } } --- 314,325 ---- public void registerPanel(Component panel, Integer placement) { if (placement.equals(SPLIT_LEFT)) { ! //splitPaneTopDown.remove(1); ! splitPaneTopDown.setTopComponent(new JScrollPane(panel)); } else if (placement.equals(SPLIT_MIDDLE)) { ! //splitPaneLeftRight.remove(1); ! splitPaneLeftRight.setRightComponent(panel); } else { ! //splitPaneTopDown.remove(2); ! splitPaneTopDown.setBottomComponent(new JScrollPane(panel)); } } *************** *** 328,332 **** settings.load(); ! setSize(800, 600); } --- 334,338 ---- settings.load(); ! setSize(1024, 768); } |