Commit 79441993 authored by Daniel Henninger's avatar Daniel Henninger Committed by dhenninger

[GATE-126] Fixed IRC contact list support.

Cleaned up a busted i18n entry.

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/trunk/src/plugins/gateway@6424 b35dd754-fafc-0310-a699-88a17e54d16e
parent 64e898cf
...@@ -156,7 +156,7 @@ global.save_changes=Save Changes ...@@ -156,7 +156,7 @@ global.save_changes=Save Changes
# Base Transport # Base Transport
gateway.base.notloggedin=You are not currently logged into the {0} transport. gateway.base.notloggedin=You are not currently logged into the {0} transport.
gateway.base.enterusername=Please enter the {0} username of the person you want to add." gateway.base.enterusername=Please enter the {0} username of the person you want to add.
# OSCAR 'Global' (both AIM/ICQ Transports) # OSCAR 'Global' (both AIM/ICQ Transports)
gateway.oscar.connectionfailed=Connection failed: gateway.oscar.connectionfailed=Connection failed:
......
...@@ -12,7 +12,7 @@ global.save_changes=Speichern ...@@ -12,7 +12,7 @@ global.save_changes=Speichern
# Base Transport # Base Transport
gateway.base.notloggedin=You are not currently logged into the {0} transport. gateway.base.notloggedin=You are not currently logged into the {0} transport.
gateway.base.enterusername=Please enter the {0} username of the person you want to add." gateway.base.enterusername=Please enter the {0} username of the person you want to add.
# OSCAR 'Global' (both AIM/ICQ Transports) # OSCAR 'Global' (both AIM/ICQ Transports)
gateway.oscar.connectionfailed=Connection failed: gateway.oscar.connectionfailed=Connection failed:
......
...@@ -76,9 +76,16 @@ public class IRCListener implements IRCEventListener { ...@@ -76,9 +76,16 @@ public class IRCListener implements IRCEventListener {
p.setFrom(getSession().getTransport().getJID()); p.setFrom(getSession().getTransport().getJID());
p.setTo(getSession().getJID()); p.setTo(getSession().getJID());
getSession().getTransport().sendPacket(p); getSession().getTransport().sendPacket(p);
getSession().setLoginStatus(TransportLoginStatus.LOGGED_IN);
String buddyList = "";
for (String buddy : getSession().getBuddyStatuses().keySet()) {
buddyList = buddyList + " " + buddy;
}
if (!buddyList.equals("")) {
getSession().getConnection().doIson(buddyList);
}
statusCheck = new StatusCheck(); statusCheck = new StatusCheck();
timer.schedule(statusCheck, timerInterval, timerInterval); timer.schedule(statusCheck, timerInterval, timerInterval);
getSession().setLoginStatus(TransportLoginStatus.LOGGED_IN);
} }
public void onDisconnected() { public void onDisconnected() {
...@@ -171,7 +178,9 @@ public class IRCListener implements IRCEventListener { ...@@ -171,7 +178,9 @@ public class IRCListener implements IRCEventListener {
Log.debug("IRC privmsg: "+chan+", "+ircUser+", "+msg); Log.debug("IRC privmsg: "+chan+", "+ircUser+", "+msg);
if (silenced) { return; } if (silenced) { return; }
if (msg.equals("VERSION")) { if (msg.equals("VERSION")) {
// TODO: Investigate if I should respond to this. What do other clients do? // This is actually a CTCP VERSION request. Why is it showing as a Privmsg?
// TODO: Should figure out a proper way to handle this.
//getSession().getConnection().send("CTCP REPLY "+ircUser.getNick()+" VERSION IM Gateway Plugin for Wildfire");
return; return;
} }
getSession().getTransport().sendMessage( getSession().getTransport().sendMessage(
...@@ -195,7 +204,7 @@ public class IRCListener implements IRCEventListener { ...@@ -195,7 +204,7 @@ public class IRCListener implements IRCEventListener {
Log.debug("IRC reply: "+i+", "+string+", "+string1); Log.debug("IRC reply: "+i+", "+string+", "+string1);
if (silenced) { return; } if (silenced) { return; }
if (i == IRCUtil.RPL_ISON) { if (i == IRCUtil.RPL_ISON) {
String[] onlineContacts = string.split(" "); String[] onlineContacts = string1.split(" ");
ArrayList<String> onlineContactList = new ArrayList<String>(); ArrayList<String> onlineContactList = new ArrayList<String>();
// Lets see who all is on // Lets see who all is on
for (String contact : onlineContacts) { for (String contact : onlineContacts) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment