Poodletooth-iLand/otp/speedchat/SCStaticTextTerminal.py
Master Jumblespeed d882959bfa switch to remote
2015-05-18 22:11:33 -04:00

18 lines
554 B
Python
Executable file

from SCTerminal import SCTerminal
from otp.otpbase.OTPLocalizer import SpeedChatStaticText
SCStaticTextMsgEvent = 'SCStaticTextMsg'
def decodeSCStaticTextMsg(textId):
return SpeedChatStaticText.get(textId, None)
class SCStaticTextTerminal(SCTerminal):
def __init__(self, textId):
SCTerminal.__init__(self)
self.textId = textId
self.text = SpeedChatStaticText[self.textId]
def handleSelect(self):
SCTerminal.handleSelect(self)
messenger.send(self.getEventName(SCStaticTextMsgEvent), [self.textId])