Added GfuiScrollListClear function + added user data support in combobox and checkbox controls
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@2586 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 5960021a4dc0d2ea86f52482106fcd79d3d241c6 Former-commit-id: 9d54f6c9a07654a39c41959d0848dc1f94a0501c
This commit is contained in:
parent
813a1420d0
commit
e3b4bd6081
4 changed files with 182 additions and 71 deletions
|
@ -196,17 +196,19 @@ typedef struct
|
|||
{
|
||||
int labelId;
|
||||
void *scr;
|
||||
tChoiceInfo *pChoices;
|
||||
tComboBoxInfo *pInfo;
|
||||
|
||||
Color fgColor[3];
|
||||
int comboType;
|
||||
tfuiComboCallback onChange;
|
||||
tfuiComboboxCallback onChange;
|
||||
} tGfuiCombobox;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int labelId;
|
||||
void *scr;
|
||||
tCheckBoxInfo *pInfo;
|
||||
|
||||
Color fgColor[3];
|
||||
int checkId;
|
||||
int uncheckId;
|
||||
|
|
|
@ -46,9 +46,8 @@ gfuiChecked(void *idv)
|
|||
|
||||
checkbox = &(object->u.checkbox);
|
||||
|
||||
|
||||
if (checkbox->onChange)
|
||||
checkbox->onChange(false);
|
||||
checkbox->onChange(checkbox->pInfo);
|
||||
|
||||
}
|
||||
|
||||
|
@ -67,15 +66,14 @@ gfuiUnchecked(void *idv)
|
|||
|
||||
checkbox = &(object->u.checkbox);
|
||||
|
||||
|
||||
if (checkbox->onChange)
|
||||
checkbox->onChange(true);
|
||||
checkbox->onChange(checkbox->pInfo);
|
||||
|
||||
}
|
||||
|
||||
int
|
||||
GfuiCheckboxCreate(void *scr, int font, int x, int y, int imagewidth,int imageheight,int align ,int style,const char *pszText,bool bChecked,
|
||||
tfuiCheckboxCallback onChange)
|
||||
void* userData, tfuiCheckboxCallback onChange)
|
||||
{
|
||||
tGfuiCheckbox *Checkbox;
|
||||
tGfuiObject *object;
|
||||
|
@ -89,6 +87,9 @@ GfuiCheckboxCreate(void *scr, int font, int x, int y, int imagewidth,int imagehe
|
|||
|
||||
Checkbox = &(object->u.checkbox);
|
||||
Checkbox->onChange = onChange;
|
||||
Checkbox->pInfo = new tCheckBoxInfo;
|
||||
Checkbox->pInfo->bChecked = bChecked;
|
||||
Checkbox->pInfo->userData = userData;
|
||||
Checkbox->scr = scr;
|
||||
|
||||
int height = gfuiFont[font]->getHeight() - gfuiFont[font]->getDescender();
|
||||
|
@ -223,16 +224,9 @@ GfuiCheckboxSetChecked(void *scr, int id, bool bChecked)
|
|||
if (curObject->widget == GFUI_CHECKBOX)
|
||||
{
|
||||
tGfuiCheckbox *Check = &(curObject->u.checkbox);
|
||||
if (bChecked)
|
||||
{
|
||||
GfuiVisibilitySet(scr,Check->checkId,true);
|
||||
GfuiVisibilitySet(scr,Check->uncheckId,false);
|
||||
}
|
||||
else
|
||||
{
|
||||
GfuiVisibilitySet(scr,Check->checkId,false);
|
||||
GfuiVisibilitySet(scr,Check->uncheckId,true);
|
||||
}
|
||||
Check->pInfo->bChecked = bChecked;
|
||||
GfuiVisibilitySet(scr,Check->checkId,bChecked);
|
||||
GfuiVisibilitySet(scr,Check->uncheckId,!bChecked);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -44,16 +44,17 @@ gfuiLeftArrow(void *idv)
|
|||
|
||||
combobox = &(object->u.combobox);
|
||||
|
||||
if (combobox->pChoices->nPos>0)
|
||||
combobox->pChoices->nPos--;
|
||||
if (combobox->pInfo->nPos>0)
|
||||
combobox->pInfo->nPos--;
|
||||
else
|
||||
combobox->pChoices->nPos = combobox->pChoices->vecChoices.size()-1;
|
||||
combobox->pInfo->nPos = combobox->pInfo->vecChoices.size()-1;
|
||||
|
||||
if (combobox->pChoices->vecChoices.size()>0)
|
||||
GfuiLabelSetText(combobox->scr,combobox->labelId,combobox->pChoices->vecChoices[combobox->pChoices->nPos].c_str());
|
||||
if (combobox->pInfo->vecChoices.size()>0)
|
||||
GfuiLabelSetText(combobox->scr, combobox->labelId,
|
||||
combobox->pInfo->vecChoices[combobox->pInfo->nPos].c_str());
|
||||
|
||||
if (combobox->onChange)
|
||||
combobox->onChange(combobox->pChoices);
|
||||
combobox->onChange(combobox->pInfo);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -68,22 +69,24 @@ gfuiRightArrow(void *idv)
|
|||
}
|
||||
|
||||
combobox = &(object->u.combobox);
|
||||
combobox->pChoices->nPos++;
|
||||
combobox->pInfo->nPos++;
|
||||
|
||||
unsigned int max = combobox->pChoices->vecChoices.size()-1;
|
||||
if (combobox->pChoices->nPos>max)
|
||||
combobox->pChoices->nPos = 0;
|
||||
unsigned int max = combobox->pInfo->vecChoices.size()-1;
|
||||
if (combobox->pInfo->nPos>max)
|
||||
combobox->pInfo->nPos = 0;
|
||||
|
||||
if (combobox->pChoices->vecChoices.size()>0)
|
||||
GfuiLabelSetText(combobox->scr,combobox->labelId,combobox->pChoices->vecChoices[combobox->pChoices->nPos].c_str());
|
||||
if (combobox->pInfo->vecChoices.size()>0)
|
||||
GfuiLabelSetText(combobox->scr, combobox->labelId,
|
||||
combobox->pInfo->vecChoices[combobox->pInfo->nPos].c_str());
|
||||
|
||||
if (combobox->onChange)
|
||||
combobox->onChange(combobox->pChoices);
|
||||
combobox->onChange(combobox->pInfo);
|
||||
}
|
||||
|
||||
int
|
||||
GfuiComboboxCreate(void *scr, int font, int x, int y, int width,int align ,int style,const char *pszText,
|
||||
tfuiComboCallback onChange)
|
||||
GfuiComboboxCreate(void *scr, int font, int x, int y, int width,
|
||||
int align, int style, const char *pszText,
|
||||
void *userData, tfuiComboboxCallback onChange)
|
||||
{
|
||||
tGfuiCombobox *combobox;
|
||||
tGfuiObject *object;
|
||||
|
@ -97,12 +100,12 @@ GfuiComboboxCreate(void *scr, int font, int x, int y, int width,int align ,int s
|
|||
|
||||
combobox = &(object->u.combobox);
|
||||
combobox->onChange = onChange;
|
||||
combobox->pChoices = new tChoiceInfo;
|
||||
combobox->pChoices->nPos = 0;
|
||||
combobox->pInfo = new tComboBoxInfo;
|
||||
combobox->pInfo->nPos = 0;
|
||||
combobox->pInfo->userData = userData;
|
||||
combobox->scr = scr;
|
||||
|
||||
int height = gfuiFont[font]->getHeight() - gfuiFont[font]->getDescender();
|
||||
|
||||
|
||||
switch (align) {
|
||||
case GFUI_ALIGN_HR_VB:
|
||||
|
@ -163,20 +166,17 @@ GfuiComboboxCreate(void *scr, int font, int x, int y, int width,int align ,int s
|
|||
break;
|
||||
}
|
||||
|
||||
|
||||
|
||||
//Create text
|
||||
int xm = object->xmin + (object->xmax-object->xmin)/2;
|
||||
int ym = object->ymin + (object->ymax-object->ymin)/2;
|
||||
int xmax = object->xmax;
|
||||
int xmin = object->xmin;
|
||||
|
||||
combobox->labelId = GfuiLabelCreate(scr,pszText,font,xm,ym,GFUI_ALIGN_HC_VC,99);
|
||||
|
||||
combobox->labelId = GfuiLabelCreate(scr, pszText, font, xm, ym, GFUI_ALIGN_HC_VC, 99);
|
||||
|
||||
GfuiGrButtonCreate(scr, "data/img/arrow-left.png", "data/img/arrow-left.png",
|
||||
"data/img/arrow-left.png", "data/img/arrow-left-pushed.png",
|
||||
xmin,ym, GFUI_ALIGN_HL_VC, GFUI_MOUSE_UP,
|
||||
xmin, ym, GFUI_ALIGN_HL_VC, GFUI_MOUSE_UP,
|
||||
(void*)(object->id), gfuiLeftArrow,
|
||||
NULL, (tfuiCallback)NULL, (tfuiCallback)NULL);
|
||||
|
||||
|
@ -187,6 +187,7 @@ GfuiComboboxCreate(void *scr, int font, int x, int y, int width,int align ,int s
|
|||
NULL, (tfuiCallback)NULL, (tfuiCallback)NULL);
|
||||
|
||||
gfuiAddObject(screen, object);
|
||||
|
||||
return object->id;
|
||||
}
|
||||
|
||||
|
@ -213,9 +214,10 @@ GfuiComboboxAddText(void *scr, int id, const char *text)
|
|||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
combo->pChoices->vecChoices.push_back(text);
|
||||
index = combo->pChoices->vecChoices.size();
|
||||
GfuiLabelSetText(combo->scr,combo->labelId,combo->pChoices->vecChoices[combo->pChoices->nPos].c_str());
|
||||
combo->pInfo->vecChoices.push_back(text);
|
||||
index = combo->pInfo->vecChoices.size();
|
||||
GfuiLabelSetText(combo->scr, combo->labelId,
|
||||
combo->pInfo->vecChoices[combo->pInfo->nPos].c_str());
|
||||
}
|
||||
return index;
|
||||
}
|
||||
|
@ -239,11 +241,12 @@ GfuiComboboxSetSelectedIndex(void *scr, int id, unsigned int index)
|
|||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
if (combo->pChoices->vecChoices.size()<= index)
|
||||
if (combo->pInfo->vecChoices.size()<= index)
|
||||
return;
|
||||
|
||||
combo->pChoices->nPos = index;
|
||||
GfuiLabelSetText(combo->scr,combo->labelId,combo->pChoices->vecChoices[combo->pChoices->nPos].c_str());
|
||||
combo->pInfo->nPos = index;
|
||||
GfuiLabelSetText(combo->scr, combo->labelId,
|
||||
combo->pInfo->vecChoices[combo->pInfo->nPos].c_str());
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
@ -266,7 +269,7 @@ GfuiComboboxSetTextColor(void *scr, int id, const Color& color)
|
|||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
GfuiLabelSetColor(combo->scr,combo->labelId,color.GetPtr());
|
||||
GfuiLabelSetColor(combo->scr, combo->labelId, color.GetPtr());
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
@ -295,7 +298,7 @@ GfuiComboboxSetPosition(void *scr, int id, unsigned int pos)
|
|||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
combo->pChoices->nPos = pos;
|
||||
combo->pInfo->nPos = pos;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
@ -322,7 +325,7 @@ GfuiComboboxGetPosition(void *scr, int id)
|
|||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
return combo->pChoices->nPos;
|
||||
return combo->pInfo->nPos;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
@ -332,12 +335,69 @@ GfuiComboboxGetPosition(void *scr, int id)
|
|||
return 0;
|
||||
}
|
||||
|
||||
const char*
|
||||
GfuiComboboxGetText(void *scr, int id)
|
||||
{
|
||||
tGfuiObject *curObject;
|
||||
tGfuiScreen *screen = (tGfuiScreen*)scr;
|
||||
char* pszText = 0;
|
||||
|
||||
curObject = screen->objects;
|
||||
if (curObject != NULL)
|
||||
{
|
||||
do
|
||||
{
|
||||
curObject = curObject->next;
|
||||
if (curObject->id == id)
|
||||
{
|
||||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
if (combo->pInfo->nPos >= 0
|
||||
&& combo->pInfo->nPos < combo->pInfo->vecChoices.size())
|
||||
return combo->pInfo->vecChoices[combo->pInfo->nPos].c_str();
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
} while (curObject != screen->objects);
|
||||
}
|
||||
|
||||
return pszText;
|
||||
}
|
||||
|
||||
void
|
||||
GfuiComboboxClear(void *scr, int id)
|
||||
{
|
||||
tGfuiObject *curObject;
|
||||
tGfuiScreen *screen = (tGfuiScreen*)scr;
|
||||
|
||||
curObject = screen->objects;
|
||||
if (curObject != NULL)
|
||||
{
|
||||
do
|
||||
{
|
||||
curObject = curObject->next;
|
||||
if (curObject->id == id)
|
||||
{
|
||||
if (curObject->widget == GFUI_COMBOBOX)
|
||||
{
|
||||
tGfuiCombobox *combo = &(curObject->u.combobox);
|
||||
combo->pInfo->nPos = 0;
|
||||
combo->pInfo->vecChoices.clear();
|
||||
GfuiLabelSetText(combo->scr, combo->labelId, "");
|
||||
}
|
||||
break;
|
||||
}
|
||||
} while (curObject != screen->objects);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
gfuiReleaseCombobox(tGfuiObject *obj)
|
||||
{
|
||||
tGfuiCombobox *combobox;
|
||||
|
||||
combobox = &(obj->u.combobox);
|
||||
delete combobox->pChoices;
|
||||
delete combobox->pInfo;
|
||||
free(obj);
|
||||
}
|
||||
|
|
|
@ -180,17 +180,27 @@ typedef struct ScrollBarInfo
|
|||
void *userData; /**< Associated user data */
|
||||
} tScrollBarInfo;
|
||||
|
||||
typedef struct ChoiceInfo
|
||||
/** Combo-box call-back information */
|
||||
typedef struct ComboBoxInfo
|
||||
{
|
||||
unsigned int nPos;
|
||||
std::vector<std::string> vecChoices;
|
||||
} tChoiceInfo;
|
||||
unsigned int nPos; /**< Currently selected choice */
|
||||
std::vector<std::string> vecChoices; /**< Possible choices */
|
||||
void *userData; /**< Associated user data */
|
||||
} tComboBoxInfo;
|
||||
|
||||
typedef void (*tfuiCallback)(void * /* userdata */);
|
||||
|
||||
/** Check-box call-back information */
|
||||
typedef struct CheckBoxInfo
|
||||
{
|
||||
bool bChecked; /**< Check-box state */
|
||||
void *userData; /**< Associated user data */
|
||||
} tCheckBoxInfo;
|
||||
|
||||
typedef void (*tfuiCallback)(void * /* userData */);
|
||||
typedef void (*tfuiSBCallback)(tScrollBarInfo *);
|
||||
typedef int (*tfuiKeyCallback)(int key, int modifier, int state); /**< return 1 to prevent normal key computing */
|
||||
typedef void (*tfuiComboCallback)(tChoiceInfo * pInfo);
|
||||
typedef void (*tfuiCheckboxCallback)(bool bChecked);
|
||||
typedef void (*tfuiComboboxCallback)(tComboBoxInfo *);
|
||||
typedef void (*tfuiCheckboxCallback)(tCheckBoxInfo *);
|
||||
|
||||
|
||||
/* Event loop callback functions (should be called explicitely if the corresponding
|
||||
|
@ -230,14 +240,56 @@ TGFCLIENT_API void GfuiInitWindowPosition(int x, int y);
|
|||
TGFCLIENT_API void GfuiInitWindowSize(int x, int y);
|
||||
TGFCLIENT_API void GfuiSwapBuffers(void);
|
||||
|
||||
// Export STL needed container types (needed with MSVC compilers).
|
||||
#ifdef WIN32
|
||||
ExportSTLVector(TGFCLIENT_API, std::string);
|
||||
#endif
|
||||
|
||||
class TGFCLIENT_API GfuiMenuScreen
|
||||
{
|
||||
public:
|
||||
GfuiMenuScreen() { m_pMenuHandle = 0; }
|
||||
void* GetMenuHandle() { return m_pMenuHandle; }
|
||||
void RunMenu() { GfuiScreenActivate(m_pMenuHandle); }
|
||||
protected:
|
||||
void* m_pMenuHandle;
|
||||
GfuiMenuScreen(const char* pszXMLDescFile);
|
||||
virtual ~GfuiMenuScreen();
|
||||
|
||||
void CreateMenu();
|
||||
void CreateMenuEx(float *bgColor,
|
||||
void *userDataOnActivate, tfuiCallback onActivate,
|
||||
void *userDataOnDeactivate, tfuiCallback onDeactivate,
|
||||
int mouseAllowed);
|
||||
void SetMenuHandle(void* hdle);
|
||||
void* GetMenuHandle() const;
|
||||
void SetPreviousMenuHandle(void* hdle);
|
||||
void* GetPreviousMenuHandle() const;
|
||||
|
||||
bool OpenXMLDescriptor();
|
||||
|
||||
bool CreateStaticControls();
|
||||
|
||||
int CreateButtonControl(const char *pszName, void *userData, tfuiCallback onPush);
|
||||
int CreateButtonControlEx(const char *pszName, void *userData, tfuiCallback onPush,
|
||||
void *userDataOnFocus, tfuiCallback onFocus,
|
||||
tfuiCallback onFocusLost);
|
||||
int CreateStaticImageControl(const char *pszName);
|
||||
int CreateLabelControl(const char *pszName);
|
||||
int CreateEditControl(const char *pszName, void *userDataOnFocus, tfuiCallback onFocus,
|
||||
tfuiCallback onFocusLost);
|
||||
int CreateScrollListControl(const char *pszName,void *userData, tfuiCallback onSelect);
|
||||
int CreateComboboxControl(const char *pszName, void *userData, tfuiComboboxCallback onChange);
|
||||
int CreateCheckboxControl(const char *pszName, void *userData, tfuiCheckboxCallback onChange);
|
||||
int CreateProgressbarControl(const char *pszName);
|
||||
|
||||
int GetDynamicControlId(const char *pszName) const;
|
||||
|
||||
void AddDefaultShortcuts();
|
||||
void AddShortcut(int key, const char *descr, void *userData,
|
||||
tfuiCallback onKeyPressed, tfuiCallback onKeyReleased);
|
||||
|
||||
bool CloseXMLDescriptor();
|
||||
|
||||
void RunMenu();
|
||||
|
||||
private:
|
||||
struct gfuiMenuPrivateData* m_priv;
|
||||
};
|
||||
|
||||
/* Mouse management */
|
||||
|
@ -308,8 +360,8 @@ TGFCLIENT_API int GfuiGrButtonCreateEx(void *scr, const char *disabled, const ch
|
|||
int x, int y, int imageWidth,int imageHeight,int align, int mouse,
|
||||
void *userDataOnPush, tfuiCallback onPush,
|
||||
void *userDataOnFocus, tfuiCallback onFocus, tfuiCallback onFocusLost);
|
||||
TGFCLIENT_API int GfuiComboboxCreate(void *scr, int font, int x, int y, int width,int align ,int style,const char *pszText,tfuiComboCallback onChange);
|
||||
TGFCLIENT_API int GfuiCheckboxCreate(void *scr, int font, int x, int y, int imagewidth,int imageheight,int align ,int style,const char *pszText,bool bChecked,tfuiCheckboxCallback onChange);
|
||||
TGFCLIENT_API int GfuiComboboxCreate(void *scr, int font, int x, int y, int width,int align ,int style,const char *pszText,void* userData,tfuiComboboxCallback onChange);
|
||||
TGFCLIENT_API int GfuiCheckboxCreate(void *scr, int font, int x, int y, int imagewidth,int imageheight,int align ,int style,const char *pszText,bool bChecked,void* userData,tfuiCheckboxCallback onChange);
|
||||
|
||||
|
||||
class TGFCLIENT_API Color
|
||||
|
@ -324,6 +376,8 @@ TGFCLIENT_API void GfuiComboboxSetTextColor(void *scr, int id, const Color& colo
|
|||
TGFCLIENT_API void GfuiComboboxSetSelectedIndex(void *scr, int id, unsigned int index);
|
||||
TGFCLIENT_API void GfuiComboboxSetPosition(void *scr, int id, unsigned int pos);
|
||||
TGFCLIENT_API unsigned int GfuiComboboxGetPosition(void *scr, int id);
|
||||
TGFCLIENT_API const char* GfuiComboboxGetText(void *scr, int id);
|
||||
TGFCLIENT_API void GfuiComboboxClear(void *scr, int id);
|
||||
|
||||
TGFCLIENT_API int GfuiProgressbarCreate(void *scr, int x, int y, int w, int h, const char *pszProgressbackImg,const char *progressbarimg, int align,float min,float max,float value);
|
||||
|
||||
|
@ -362,6 +416,7 @@ TGFCLIENT_API int GfuiScrollListInsertElement(void *scr, int Id, const char *ele
|
|||
TGFCLIENT_API int GfuiScrollListMoveSelectedElement(void *scr, int Id, int delta);
|
||||
TGFCLIENT_API const char *GfuiScrollListExtractSelectedElement(void *scr, int Id, void **userData);
|
||||
TGFCLIENT_API const char *GfuiScrollListExtractElement(void *scr, int Id, int index, void **userData);
|
||||
TGFCLIENT_API void GfuiScrollListClear(void *scr, int Id);
|
||||
TGFCLIENT_API const char *GfuiScrollListGetSelectedElement(void *scr, int Id, void **userData);
|
||||
TGFCLIENT_API bool GfuiScrollListSetSelectedElement(void *scr, int Id, unsigned int selectElement);
|
||||
TGFCLIENT_API const char *GfuiScrollListGetElement(void *scr, int Id, int index, void **userData);
|
||||
|
@ -390,8 +445,8 @@ TGFCLIENT_API void GfuiStaticImageSetActive(void *scr, int id, int index);
|
|||
|
||||
TGFCLIENT_API void *GfuiMenuScreenCreate(const char *title);
|
||||
TGFCLIENT_API void GfuiMenuDefaultKeysAdd(void *scr);
|
||||
TGFCLIENT_API int GfuiMenuButtonCreate(void *menu, const char *text, const char *tip, void *userdata, const int style, tfuiCallback onpush);
|
||||
TGFCLIENT_API int GfuiMenuBackQuitButtonCreate(void *menu, const char *text, const char *tip, void *userdata, tfuiCallback onpush);
|
||||
TGFCLIENT_API int GfuiMenuButtonCreate(void *menu, const char *text, const char *tip, void *userData, const int style, tfuiCallback onpush);
|
||||
TGFCLIENT_API int GfuiMenuBackQuitButtonCreate(void *menu, const char *text, const char *tip, void *userData, tfuiCallback onpush);
|
||||
|
||||
/*******************************************
|
||||
* New XML based Menu Management Interface *
|
||||
|
@ -400,14 +455,14 @@ TGFCLIENT_API int GfuiMenuBackQuitButtonCreate(void *menu, const char *text, c
|
|||
TGFCLIENT_API void *LoadMenuXML(const char *pFilePath);
|
||||
TGFCLIENT_API bool CreateStaticControls(void *param,void *menuHandle);
|
||||
|
||||
TGFCLIENT_API int CreateButtonControl(void *menuHandle,void *param,const char *pControlName,void *userdata, tfuiCallback onpush);
|
||||
TGFCLIENT_API int CreateButtonControlEx(void *menuHandle,void *param,const char *pControlName,void *userdata, tfuiCallback onpush, void *userDataOnFocus, tfuiCallback onFocus, tfuiCallback onFocusLost);
|
||||
TGFCLIENT_API int CreateButtonControl(void *menuHandle,void *param,const char *pControlName,void *userData, tfuiCallback onPush);
|
||||
TGFCLIENT_API int CreateButtonControlEx(void *menuHandle,void *param,const char *pControlName,void *userData, tfuiCallback onPush, void *userDataOnFocus, tfuiCallback onFocus, tfuiCallback onFocusLost);
|
||||
TGFCLIENT_API int CreateStaticImageControl(void *menuHandle,void *param,const char *pControlName);
|
||||
TGFCLIENT_API int CreateLabelControl(void *menuHandle,void *param,const char *pControlName);
|
||||
TGFCLIENT_API int CreateEditControl(void *menuHandle,void *param,const char *pControlName,void *userDataOnFocus, tfuiCallback onFocus, tfuiCallback onFocusLost);
|
||||
TGFCLIENT_API int CreateScrollListControl(void *menuHandle,void *param,const char *pControlName,void *userdata, tfuiCallback onSelect);
|
||||
TGFCLIENT_API int CreateComboboxControl(void *menuHandle,void *param,const char *pControlName,tfuiComboCallback onChange);
|
||||
TGFCLIENT_API int CreateCheckboxControl(void *menuHandle,void *param,const char *pControlName,tfuiCheckboxCallback onChange);
|
||||
TGFCLIENT_API int CreateScrollListControl(void *menuHandle,void *param,const char *pControlName,void *userData, tfuiCallback onSelect);
|
||||
TGFCLIENT_API int CreateComboboxControl(void *menuHandle,void *param,const char *pControlName,void *userData,tfuiComboboxCallback onChange);
|
||||
TGFCLIENT_API int CreateCheckboxControl(void *menuHandle,void *param,const char *pControlName,void *userData,tfuiCheckboxCallback onChange);
|
||||
TGFCLIENT_API int CreateProgressbarControl(void *menuHandle,void *param,const char *pControlName);
|
||||
|
||||
TGFCLIENT_API void GfuiButtonShowBox(void *scr, int id,bool bShow);
|
||||
|
|
Loading…
Reference in a new issue