Changeset 23262 in osm
- Timestamp:
- 2010-09-19T12:09:41+02:00 (14 years ago)
- Location:
- applications/editors/josm/plugins/smed
- Files:
-
- 3 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/smed/src/smed/menu/SmedMenuBar.java
r23261 r23262 6 6 import javax.swing.JMenuBar; 7 7 import javax.swing.JMenuItem; 8 import javax.swing.JPanel; 9 10 import smed.menu.file.HideAction; 8 11 9 12 public class SmedMenuBar extends JMenuBar { … … 30 33 31 34 menuItem.addActionListener(new java.awt.event.ActionListener() { 32 public void actionPerformed(java.awt.event.ActionEvent e) { 33 System.out.println("actionPerformed()"); // TODO Auto-generated Event stub actionPerformed() 34 } 35 }); 35 36 public void actionPerformed(java.awt.event.ActionEvent e) { 37 JPanel panelHide = new HideAction(); 38 panelHide.setVisible(true); 39 } 40 }); 36 41 37 42 -
applications/editors/josm/plugins/smed/src/smed/menu/file/HideAction.java
r23259 r23262 1 1 package smed.menu.file; 2 2 3 public class HideAction { 3 import javax.swing.JPanel; 4 import java.awt.GridBagLayout; 5 import java.awt.Dimension; 6 import javax.swing.JButton; 7 import java.awt.GridBagConstraints; 8 import javax.swing.JList; 9 import java.awt.Rectangle; 10 11 public class HideAction extends JPanel { 12 13 /** 14 * 15 */ 16 private static final long serialVersionUID = 1L; 17 private JPanel jPanel = null; // @jve:decl-index=0:visual-constraint="80,35" 18 private JButton jButton = null; 19 private JList jList = null; 20 /** 21 * This method initializes jPanel 22 * 23 * @return javax.swing.JPanel 24 */ 25 private JPanel getJPanel() { 26 if (jPanel == null) { 27 jPanel = new JPanel(); 28 jPanel.setLayout(null); 29 jPanel.setSize(new Dimension(296, 443)); 30 jPanel.add(getJButton(), null); 31 jPanel.add(getJList(), null); 32 } 33 return jPanel; 34 } 35 /** 36 * This method initializes jButton 37 * 38 * @return javax.swing.JButton 39 */ 40 private JButton getJButton() { 41 if (jButton == null) { 42 jButton = new JButton(); 43 jButton.setBounds(new Rectangle(90, 391, 114, 35)); 44 jButton.setText("Ok"); 45 } 46 return jButton; 47 } 48 /** 49 * This method initializes jList 50 * 51 * @return javax.swing.JList 52 */ 53 private JList getJList() { 54 if (jList == null) { 55 jList = new JList(); 56 jList.setBounds(new Rectangle(34, 43, 230, 307)); 57 } 58 return jList; 59 } 4 60 5 61 }
Note:
See TracChangeset
for help on using the changeset viewer.