Package nu.fw.jeti.plugins.buddyspacemaps.editor

Examples of nu.fw.jeti.plugins.buddyspacemaps.editor.BSJIDLabel


                String nick = null;
                JIDStatus j = Roster.getJIDStatus(jid);
                if (j != null) nick = j.getNick();
                if (nick == null) nick = "?";
               
                BSJIDLabel jidLabel = new BSJIDLabel(jid, nick, getIconForPresence(0));
                jidLabel.setOpaque(false);
                Icon onlineIcon = getIconForPresence(Presence.AVAILABLE);
                if (onlineIcon != null) {
                    w = onlineIcon.getIconWidth();
                    h = onlineIcon.getIconHeight();
                }
                int x = Math.round(i.getLonFloat()*newScale + newOffsetX - w/2);
                int y = Math.round(i.getLatFloat()*newScale + newOffsetY - h/2);
                //mainPanel.add(jidLabel, new AbsoluteConstraints(x, y, w, h));
                //mainPanel.add(jidLabel, JLayeredPane.DEFAULT_LAYER, layerNum);
                mainPanel.add(jidLabel, new Integer(layerNum));
                jidLabel.setBounds(x + insets.left, y + insets.top, w, h);
                jidLabel.addMouseListener(this);
                registerJIDLabel(jidLabel);
            }
            // else if it's cluster
            else if (o instanceof ClusterTag) {
                ClusterTag c = (ClusterTag) o;
View Full Code Here


   
    /** Sets icon for all labels in the list */
    public void setImg(Icon img) {
        Enumeration elements = jidLabels.elements();
        while (elements.hasMoreElements()) {
            BSJIDLabel elem = (BSJIDLabel) elements.nextElement();
            elem.setImg(img);
        }
    }
View Full Code Here

   
    /** Sets nick for all labels in the list */
    public void setNick(String nick) {
        Enumeration elements = jidLabels.elements();
        while (elements.hasMoreElements()) {
            BSJIDLabel elem = (BSJIDLabel) elements.nextElement();
            elem.setNick(nick);
        }
    }
View Full Code Here

TOP

Related Classes of nu.fw.jeti.plugins.buddyspacemaps.editor.BSJIDLabel

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.