Skip to content

Commit

Permalink
Add an informational message for when the MOTD is ignored.
Browse files Browse the repository at this point in the history
  • Loading branch information
Darren Salt authored and pocmo committed Jul 2, 2011
1 parent 9dba05e commit 2759b00
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions application/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@
<string name="message_connected">Connected to %1$s</string>
<string name="message_now_login">Now logging in...</string>
<string name="message_login_done">Server login done.</string>
<string name="message_motd_suppressed">MOTD suppressed. To see it, use the ‘/motd’ command.</string>
<string name="message_deop">%1$s deops %2$s</string>
<string name="message_devoice">%1$s devoices %2$s</string>
<string name="message_invite_you">%1$s invites you into %2$s</string>
Expand Down
3 changes: 3 additions & 0 deletions application/src/org/yaaic/irc/IRCConnection.java
Original file line number Diff line number Diff line change
Expand Up @@ -1098,6 +1098,9 @@ protected void onServerResponse(int code, String response)
return;
}
if (code == 376 && ignoreMOTD) {
Message motdMessage = new Message(service.getString(R.string.message_motd_suppressed));
motdMessage.setColor(Message.COLOR_GREY);
server.getConversation(ServerInfo.DEFAULT_NAME).addMessage(motdMessage);
ignoreMOTD = false;
return;
}
Expand Down

0 comments on commit 2759b00

Please sign in to comment.