Package cz.cuni.mff.inetpaint.swing

Examples of cz.cuni.mff.inetpaint.swing.StatusSelectorMenu


        statusSelector = new JButton();
        statusSelector.addActionListener(new ActionListener() {
            @Override
            public void actionPerformed(ActionEvent e) {
                StatusSelectorMenu menu = new StatusSelectorMenu();
                menu.addPresenceChangedListener(new StatusSelectorMenu.PresenceChangedListener() {
                    @Override
                    public void presenceModeUpdated(Mode mode) {
                        setStatusSelector(mode);
                        //udelat status field
                        String status = (statusField.getForeground() == Color.gray) ? "" : statusField.getText();
                       
                        ConnectionManager.getInstance().updatePresence(Presence.Type.available, status, 20, mode);           
                    }
                });
                menu.show(statusSelector, 2, statusSelector.getHeight() + 2);
            }
        });
        statusSelector.setFocusable(false);
        statusSelector.setRolloverEnabled(true);
View Full Code Here

TOP

Related Classes of cz.cuni.mff.inetpaint.swing.StatusSelectorMenu

Copyright © 2018 www.massapicom. 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.