Added a test to make sure uiEntryOnChanged() isn't triggered by uiEntrySetText().
This commit is contained in:
parent
349d54b2f1
commit
9500f25b62
|
@ -24,6 +24,11 @@ TEXT(Button, uiButton, uiButtonText, uiButtonSetText)
|
|||
TEXT(Checkbox, uiCheckbox, uiCheckboxText, uiCheckboxSetText)
|
||||
TEXT(Label, uiLabel, uiLabelText, uiLabelSetText)
|
||||
|
||||
static void onChanged(uiEntry *e, void *data)
|
||||
{
|
||||
printf("onChanged()\n");
|
||||
}
|
||||
|
||||
static void toggleSpaced(uiCheckbox *c, void *data)
|
||||
{
|
||||
setSpaced(uiCheckboxChecked(spaced));
|
||||
|
@ -64,6 +69,7 @@ void makePage1(uiWindow *w)
|
|||
page1 = newVerticalBox();
|
||||
|
||||
entry = uiNewEntry();
|
||||
uiEntryOnChanged(entry, onChanged, NULL);
|
||||
uiBoxAppend(page1, uiControl(entry), 0);
|
||||
|
||||
spaced = uiNewCheckbox("Spaced");
|
||||
|
|
Loading…
Reference in New Issue