Examples of removeActionListener()


Examples of javax.swing.JMenuItem.removeActionListener()

        mi.removeActionListener(this);
        mi.addActionListener(this);
        skinsSubMenu.add(mi);
        mi = new JMenuItem(ui.getResource("popup.skins.load"));
        mi.setActionCommand(PlayerActionEvent.MILOADSKIN);
        mi.removeActionListener(this);
        mi.addActionListener(this);
        skinsSubMenu.add(mi);
        mainpopup.add(skinsSubMenu);
        JMenu playbackSubMenu = new JMenu(ui.getResource("popup.playback"));
        mi = new JMenuItem(ui.getResource("popup.playback.jump"));
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        mainpopup.add(skinsSubMenu);
        JMenu playbackSubMenu = new JMenu(ui.getResource("popup.playback"));
        mi = new JMenuItem(ui.getResource("popup.playback.jump"));
        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_J, 0, false));
        mi.setActionCommand(PlayerActionEvent.MIJUMPFILE);
        mi.removeActionListener(this);
        mi.addActionListener(this);
        playbackSubMenu.add(mi);
        mi = new JMenuItem(ui.getResource("popup.playback.stop"));
        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_V, 0, false));
        mi.setActionCommand(PlayerActionEvent.MISTOP);
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        mi.addActionListener(this);
        playbackSubMenu.add(mi);
        mi = new JMenuItem(ui.getResource("popup.playback.stop"));
        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_V, 0, false));
        mi.setActionCommand(PlayerActionEvent.MISTOP);
        mi.removeActionListener(this);
        mi.addActionListener(this);
        playbackSubMenu.add(mi);
        mainpopup.add(playbackSubMenu);
        mainpopup.addSeparator();
        mi = new JMenuItem(ui.getResource("popup.exit"));
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        playbackSubMenu.add(mi);
        mainpopup.add(playbackSubMenu);
        mainpopup.addSeparator();
        mi = new JMenuItem(ui.getResource("popup.exit"));
        mi.setActionCommand(PlayerActionEvent.ACEXIT);
        mi.removeActionListener(this);
        mi.addActionListener(this);
        mainpopup.add(mi);
        // Popup menu on TitleBar
        ui.getAcTitleBar().removeMouseListener(popupAdapter);
        popupAdapter = new PopupAdapter(mainpopup);
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        ui.getAcTitleBar().addMouseListener(popupAdapter);
        // Popup menu on Eject button
        ejectpopup = new JPopupMenu();
        mi = new JMenuItem(ui.getResource("popup.eject.openfile"));
        mi.setActionCommand(PlayerActionEvent.MIPLAYFILE);
        mi.removeActionListener(this);
        mi.addActionListener(this);
        ejectpopup.add(mi);
        mi = new JMenuItem(ui.getResource("popup.eject.openlocation"));
        mi.setActionCommand(PlayerActionEvent.MIPLAYLOCATION);
        mi.removeActionListener(this);
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        mi.removeActionListener(this);
        mi.addActionListener(this);
        ejectpopup.add(mi);
        mi = new JMenuItem(ui.getResource("popup.eject.openlocation"));
        mi.setActionCommand(PlayerActionEvent.MIPLAYLOCATION);
        mi.removeActionListener(this);
        mi.addActionListener(this);
        ejectpopup.add(mi);
        ui.getAcEject().removeMouseListener(ejectpopupAdapter);
        ejectpopupAdapter = new PopupAdapter(ejectpopup);
        ui.getAcEject().addMouseListener(ejectpopupAdapter);
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        String[] presets = { "Normal", "Classical", "Club", "Dance", "Full Bass", "Full Bass & Treble", "Full Treble", "Laptop", "Live", "Party", "Pop", "Reggae", "Rock", "Techno" };
        JMenuItem mi;
        for (int p = 0; p < presets.length; p++)
        {
            mi = new JMenuItem(presets[p]);
            mi.removeActionListener(this);
            mi.addActionListener(this);
            mainpopup.add(mi);
        }
        ui.getAcEqPresets().removeActionListener(this);
        ui.getAcEqPresets().addActionListener(this);
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

//            if (actionCount > 0) {
//                for (ActionListener listener : item.getActionListeners()){
//                    item.removeActionListener(listener);
//                }
//            }
            item.removeActionListener(this);
            item.addActionListener(this);
        } else if (o instanceof MenuList) {
            MenuList item = (MenuList)o;
            // TF:18/06/2008:removed this as I don't understand why it's there
//            int actionCount = item.getActionListeners().length;
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

//            if (actionCount > 0) {
//                for (ActionListener listener : item.getActionListeners()){
//                    item.removeActionListener(listener);
//                }
//            }
            item.removeActionListener(this);
            item.addActionListener(this);
        }
    }

    public void actionPerformed(ActionEvent e) {
View Full Code Here

Examples of javax.swing.JMenuItem.removeActionListener()

        if (o instanceof JMenuItem) {
            JMenuItem item = (JMenuItem)o;
            int actionCount = item.getActionListeners().length;
            if (actionCount > 0) {
                for (ActionListener listener : item.getActionListeners()){
                    item.removeActionListener(listener);
                }
            }
            item.addActionListener(this);
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.