application/main.c

changeset 967
ff4a8d10307b
parent 966
e411ed7c5f10
child 969
7385c26d998d
equal deleted inserted replaced
966:e411ed7c5f10 967:ff4a8d10307b
407 407
408 408
409 void action_group1(UiEvent *event, void *userdata) { 409 void action_group1(UiEvent *event, void *userdata) {
410 UiContext *ctx = event->obj->ctx; 410 UiContext *ctx = event->obj->ctx;
411 if(userdata) { 411 if(userdata) {
412 ui_unset_group(ctx, 1); 412 ui_unset_state(ctx, 1);
413 } else { 413 } else {
414 ui_set_group(ctx, 1); 414 ui_set_state(ctx, 1);
415 } 415 }
416 } 416 }
417 417
418 void action_group2(UiEvent *event, void *userdata) { 418 void action_group2(UiEvent *event, void *userdata) {
419 UiContext *ctx = event->obj->ctx; 419 UiContext *ctx = event->obj->ctx;
420 if(userdata) { 420 if(userdata) {
421 ui_unset_group(ctx, 2); 421 ui_unset_state(ctx, 2);
422 } else { 422 } else {
423 ui_set_group(ctx, 2); 423 ui_set_state(ctx, 2);
424 } 424 }
425 } 425 }
426 426
427 static UiObject *ref_window; 427 static UiObject *ref_window;
428 428
1000 } 1000 }
1001 1001
1002 static void action_show_button1(UiEvent *event, void *data) { 1002 static void action_show_button1(UiEvent *event, void *data) {
1003 WData *wdata = event->window; 1003 WData *wdata = event->window;
1004 if(event->intval) { 1004 if(event->intval) {
1005 ui_set_group(event->obj->ctx, 10); 1005 ui_set_state(event->obj->ctx, 10);
1006 } else { 1006 } else {
1007 ui_unset_group(event->obj->ctx, 10); 1007 ui_unset_state(event->obj->ctx, 10);
1008 } 1008 }
1009 } 1009 }
1010 1010
1011 void application_startup(UiEvent *event, void *data) { 1011 void application_startup(UiEvent *event, void *data) {
1012 1012
1062 1062
1063 } 1063 }
1064 } 1064 }
1065 1065
1066 ui_set(wdata->checkbox1, 1); 1066 ui_set(wdata->checkbox1, 1);
1067 ui_set_group(obj->ctx, 10); 1067 ui_set_state(obj->ctx, 10);
1068 1068
1069 1069
1070 ui_show(obj); 1070 ui_show(obj);
1071 1071
1072 ui_set(wdata->spinner, 1); 1072 ui_set(wdata->spinner, 1);

mercurial