Allow a message to specify the name to display for a user separate from the canonical username passed in the message as the speaker variable.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4313 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -61,4 +61,14 @@ public class UserMessage extends ChatMessage
|
||||
this.speaker = speaker;
|
||||
this.mode = ChatCodes.DEFAULT_MODE;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the name to display for the speaker. Some types of messages
|
||||
* may wish to not use the canonical name for the speaker and should thus
|
||||
* override this function.
|
||||
*/
|
||||
public Name getSpeakerDisplayName ()
|
||||
{
|
||||
return speaker;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user