Differential D2412 Diff 10371 ps/trunk/binaries/data/mods/public/gui/lobby/LobbyPage/Chat/ChatMessages/ChatMessagePrivateWrapper.js
Changeset View
Changeset View
Standalone View
Standalone View
ps/trunk/binaries/data/mods/public/gui/lobby/LobbyPage/Chat/ChatMessages/ChatMessagePrivateWrapper.js
Property | Old Value | New Value |
---|---|---|
svn:eol-style | null | native \ No newline at end of property |
/** | |||||
* This class adds an indication that the chat message was a private message to the given text. | |||||
*/ | |||||
class ChatMessagePrivateWrapper | |||||
{ | |||||
constructor() | |||||
{ | |||||
this.args = { | |||||
"private": setStringTags(this.PrivateFormat, this.PrivateMessageTags) | |||||
}; | |||||
} | |||||
/** | |||||
* Text is formatted, escapeText is the responsibility of the caller. | |||||
*/ | |||||
format(text) | |||||
{ | |||||
this.args.message = text; | |||||
return sprintf(this.PrivateMessageFormat, this.args); | |||||
} | |||||
} | |||||
ChatMessagePrivateWrapper.prototype.PrivateFormat = translate("Private"); | |||||
ChatMessagePrivateWrapper.prototype.PrivateMessageFormat = translate("(%(private)s) %(message)s"); | |||||
/** | |||||
* Color for private messages in the chat. | |||||
*/ | |||||
ChatMessagePrivateWrapper.prototype.PrivateMessageTags = { | |||||
"color": "0 150 0" | |||||
}; |
Wildfire Games · Phabricator