]> ruin.nu Git - moosique.git/commitdiff
försöker och försöker
authorBjörn Lanneskog <lannesko@itstud.chalmers.se>
Wed, 7 May 2003 13:37:04 +0000 (13:37 +0000)
committerBjörn Lanneskog <lannesko@itstud.chalmers.se>
Wed, 7 May 2003 13:37:04 +0000 (13:37 +0000)
MooToolbar.java

index bca5b5430e69b2032e8940c59f1e887a1d1382d4..2415b3bbbbbd97af56e0807c2c59b53fb5865e3a 100644 (file)
@@ -1,7 +1,7 @@
 import javax.swing.*;
 import java.awt.event.*;
 
-public class MooToolbar extends JToolBar implements ActionListener     {
+public class MooToolbar extends JToolBar       {
 
        public MooToolbar()     {
        
@@ -17,31 +17,44 @@ public class MooToolbar extends JToolBar implements ActionListener  {
                fastforward = createButton("images/forward.gif", "fast forward");
                add(fastforward);
                
+               meas = createProgressIndikator("meas");
+               add(meas);
                }
                
                private JButton createButton(String imageLocation, String toolTip) {
                        JButton button = new JButton (new ImageIcon(imageLocation));
                        button.setToolTipText(toolTip);
-                       button.addActionListener(this);
                        return button;
                }
                
-               public void actionPerformed(ActionEvent e) {
-                       Object ob = e.getActionCommand();
+               private JPanel createProgressIndikator(String name) {
+                       JPanel panel = new JPanel();
+                       JLabel label = new JLabel(name);
+                       JComboBox combo = new JComboBox();
+                       add(label);
+                       add(combo);
+                       return panel;
                        
-                       if (ob == rewind) {
+               
+               }
+               
+               /*public void actionPerformed(ActionEvent e) {
+                       String but = e.getActionCommand();
                        
-                       } else if (ob == playpause) {
+                       if (but == "rewind") {
+                       
+                       } else if (but == "images/play.gif") {
                                JOptionPane.showMessageDialog(null, "playing");
                        
-                       } else if (ob == stop) {
+                       } else if (but == "stop") {
                        
-                       } else if (ob == rewind) {
+                       } else if (but == "rewind") {
                        
                        }
-               }
+               }*/
                private JButton rewind;
                private JButton playpause;
                private JButton stop;
                private JButton fastforward;
+               private JPanel meas;
 }