29 #include "../idlib/precompiled.h"
89 if ( !
idStr::Cmpn( eventName,
"cvar read ", 10 ) ) {
91 group =
event.
Mid( 10, event.
Length() - 10 );
95 }
else if ( !
idStr::Cmpn( eventName,
"cvar write ", 11 ) ) {
97 group =
event.
Mid( 11, event.
Length() - 11 );
121 bool runAction =
false;
122 bool runAction2 =
false;
125 key =
event->evValue;
160 key =
event->evValue;
162 int potentialChoice = -1;
164 if ( toupper(key) == toupper(
choices[
i][0]) ) {
168 potentialChoice = -1;
174 if ( potentialChoice >= 0 ) {
191 }
else if (
values.Num() ) {
207 if ( currentChoice < 0 || currentChoice >=
choices.
Num() ) {
232 for ( i = 0; i <
c; i++ ) {
294 if ( token ==
";" ) {
GLboolean GLenum GLenum GLvoid * values
virtual void Draw(int time, float x, float y)
int Cmp(const char *text) const
idChoiceWindow(idUserInterfaceLocal *gui)
idCVarSystem * cvarSystem
bool Contains(float x, float y)
virtual void virtual void virtual const idLangDict * GetLanguageDict(void)=0
void UpdateVars(bool read, bool force=false)
void RunNamedEvent(const char *eventName)
virtual bool ParseInternalVar(const char *name, idParser *src)
void StripTrailingWhitespace(void)
int Cmpn(const char *text, int n) const
int Icmp(const char *text) const
virtual void Activate(bool activate, idStr &act)
virtual const char * HandleEvent(const sysEvent_t *event, bool *updateVisuals)
virtual idCVar * Find(const char *name)=0
virtual void Activate(bool activate, idStr &act)
void SetString(const char *value)
int DrawText(const char *text, float textScale, int textAlign, idVec4 color, idRectangle rectDraw, bool wrap, int cursor=-1, bool calcOnly=false, idList< int > *breaks=NULL, int limit=0)
void UpdateChoicesAndVals(void)
const char * GetSourceFile(void) const
const char * GetString(const char *str) const
idStr & RemoveColors(void)
int LoadMemory(const char *ptr, int length, const char *name, int startLine=1)
virtual ~idChoiceWindow()
const char * GetString(void) const
int Append(const type &obj)
const char * Mid(int start, int len, idStr &result) const
idUserInterfaceLocal * gui
virtual const char * c_str() const
void SetGuiInfo(idDict *dict)
virtual bool ParseInternalVar(const char *name, idParser *src)
char * va(const char *fmt,...)
virtual void Set(const char *val)
virtual void virtual void Warning(const char *fmt,...) id_attribute((format(printf
virtual idWinVar * GetWinVarByName(const char *_name, bool winLookup=false, drawWin_t **owner=NULL)
int ReadToken(idToken *token)
virtual idWinVar * GetWinVarByName(const char *_name, bool winLookup=false, drawWin_t **owner=NULL)