From d51ea6901486e69a2e829991e7a9bd8e25d35e31 Mon Sep 17 00:00:00 2001 From: Danny van Heumen Date: Tue, 29 Jul 2014 23:49:53 +0200 Subject: [PATCH] Removed comments, TODOs. --- .../impl/protocol/irc/IrcStack.java | 22 +++++++------------ .../event/MessageDeliveryFailedEvent.java | 2 +- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java b/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java index 068f69595..a799d3f1c 100644 --- a/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java +++ b/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java @@ -508,7 +508,7 @@ public List getServerChatRoomList() } list = listSignal.getValue(); this.channellist.set(list); - LOGGER.trace("Finished retrieve server chat room list."); + LOGGER.trace("Finished retrieving server chat room list."); } else { @@ -746,9 +746,6 @@ public void onFailure(final Exception e) public void leave(final ChatRoomIrcImpl chatroom) { LOGGER.trace("Leaving chat room '" + chatroom.getIdentifier() + "'."); - - // You only actually join non-private chat rooms, so only these ones - // need to be left. leave(chatroom.getIdentifier()); } @@ -852,7 +849,8 @@ public void command(final Contact contact, final MessageIrcImpl message) } /** - * Implementation of some commands. + * Implementation of some commands. If the command is not recognized or + * implemented, it will be sent as if it were a normal message. * * TODO Eventually replace this with a factory such that we can easily * extend with new commands. @@ -926,7 +924,7 @@ public void message(final ChatRoomIrcImpl chatroom, final String message) throw new IllegalStateException("Not connected to an IRC server."); } final IRCApi irc = this.session.get(); - String target = chatroom.getIdentifier(); + final String target = chatroom.getIdentifier(); irc.message(target, message); } @@ -1198,14 +1196,14 @@ public void onServerNumericMessage(final ServerNumericMessage msg) final int endOfTargetIndex = msgText.indexOf(' '); if (endOfTargetIndex == -1) { - LOGGER.trace("Expected source nick name in error message, " - + "but it cannot be found. Stop parsing."); + LOGGER.trace("Expected target nick in error message, but " + + "it cannot be found. Stop parsing."); break; } final String targetNick = msgText.substring(0, endOfTargetIndex); - final String msgTextError = - msgText.substring(endOfTargetIndex + 2); + // Send blank text string as the message, since we don't know + // what the actual message was. MessageIrcImpl message = new MessageIrcImpl( "", @@ -1419,10 +1417,6 @@ public void onUserQuit(final QuitMessage msg) // set this way) and it turns out the user is online? Can we send it // a message then? (Or would Jitsi block this, because there is no // support for off-line messaging.) - - // TODO Also respond to private messages that are undeliverable - // because the user is not available anymore. - // 401 - :No such nick/channel } } diff --git a/src/net/java/sip/communicator/service/protocol/event/MessageDeliveryFailedEvent.java b/src/net/java/sip/communicator/service/protocol/event/MessageDeliveryFailedEvent.java index 220361321..85fc5e87f 100644 --- a/src/net/java/sip/communicator/service/protocol/event/MessageDeliveryFailedEvent.java +++ b/src/net/java/sip/communicator/service/protocol/event/MessageDeliveryFailedEvent.java @@ -11,7 +11,7 @@ import net.java.sip.communicator.service.protocol.*; /** - * MessageDeliveredEvents confirm successful delivery of an instant + * MessageDeliveryFailedEvents inform of failed delivery of an instant * message. * * @author Emil Ivov