Package com.cellasoft.jchat.utils

Examples of com.cellasoft.jchat.utils.JListClientItem


    }

    public void updateList(String name, boolean connect) throws RemoteException {
        if (name != null) {
            if (connect && !users.contains(name)) {
                model.addElement(new JListClientItem(name, name, "chat/resources/person.png"));
                users.add(name);
            } else {
                model.removeElementAt(users.indexOf(name));
                users.remove(name);
            }
            return;
        }
        LinkedList<String> usersList = admin.getClientsList();
        if (users != null) {
            for (Iterator<String> it = usersList.iterator(); it.hasNext();) {
                String nick = it.next();
                if (!username.equals(nick) && !users.contains(nick)) {
                    model.addElement(new JListClientItem(nick, nick, "chat/resources/person.png"));
                    users.add(nick);
                }
            }
        }
        userList.setModel(model);
View Full Code Here


    }

    public void updateList(String name, boolean connect) throws RemoteException {
        if (name != null) {
            if (connect && !users.contains(name)) {
                model.addElement(new JListClientItem(name, name, "chat/resources/person.png"));
                users.add(name);
            } else {
                model.removeElementAt(users.indexOf(name));
                users.remove(name);
            }
            return;
        }
        LinkedList<String> usersList = user.getClientsList();
        if (users != null) {
            for (Iterator<String> it = usersList.iterator(); it.hasNext();) {
                String nick = it.next();
                if (!username.equals(nick) && !users.contains(nick)) {
                    model.addElement(new JListClientItem(nick, nick, "chat/resources/person.png"));
                    users.add(nick);
                }
            }
        }
        userList.setModel(model);
View Full Code Here

TOP

Related Classes of com.cellasoft.jchat.utils.JListClientItem

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.