Share

JClaim

The forum address has changed, you have been automatically redirected. Please update any bookmarks to use the new URL.

Subscribe

YM Friend's Online/Offline not updated!

You are viewing a single message from this topic. View all messages.

  1. 2007-07-03 16:38:27 UTC
    Hi,

    I got a problem in which the online/offline status of the contacts are not updated when a contact goes online or offline.
    In my friendsUpdatedReceived method,

    public void friendsUpdateReceived(SessionFriendEvent ev) {
    for (YahooUser aYu : ev.getFriends()) {
    // log.fine("Updated: " + yu[i].toString());
    if (aYu==null) continue;
    Contact contact = getContactFactory().create(aYu.getId(), YMsgConnection.this);
    //YMsgConnection.
    /* for (int i = 0; i < getGroupList().size(); i++) {
    Group group = getGroupList().get(i);
    GroupImpl gw = (GroupImpl) group;
    System.err.println("Group " + i + ":" + gw.getName());
    for (int j = 0; j < group.size(); j++) {
    Nameable contact = group.get(j);
    PeopleContact peopleContact = new PeopleContact();
    if (contact instanceof ContactImpl) {
    ContactImpl cw = (ContactImpl) contact;
    System.err.print("Contact:" + cw.getName() + " ");
    System.err.println(cw.getDisplayName() + "~" + cw.getStatus());
    StatusImpl sw = (StatusImpl) cw.getStatus();
    peopleContact.setName(cw.getName());
    peopleContact.setDisplayName(cw.getDisplayName());

    }
    }
    }*/
    /*Group group = getGroupFactory().create(ev.getGroup());
    group.add(getContactFactory().create(ev.getFriend().getId(), YMsgConnection.this));
    getGroupList().add(group);*/
    System.err.println("YMsgConnection= " + contact.getDisplayName());
    for (ConnectionEventListener eventHandler : eventHandlers) { //online: info.getOnSince().getTime() > 0
    System.err.println("isLoggenIn=" + aYu.isLoggedIn() + " , isAway=" + isAway(aYu));
    eventHandler.statusChanged(YMsgConnection.this, contact, aYu.isLoggedIn(), isAway(aYu), 0);
    }
    }
    }
< Previous | 1 | Next >

Add a Reply

This forum does not allow anonymous participation.

Log in to add a reply. Not registered? Create an account to participate and receive email updates when replies are posted to this topic.