MCPcopy Create free account
hub / github.com/Kitware/CMake / _nc_Set_Form_Page

Function _nc_Set_Form_Page

Source/CursesDialog/form/frm_driver.c:3325–3355  ·  view source on GitHub ↗

--------------------------------------------------------------------------- | Facility : libnform | Function : int _nc_Set_Form_Page(FORM * form, | int page, | FIELD * field) | | Description : Make the given page nr. the current page and make | the given field the current

Source from the content-addressed store, hash-verified

3323/*----------------------------------------------------------------------------
3324 Helper routines for Page Navigation
3325 --------------------------------------------------------------------------*/
3326
3327/*---------------------------------------------------------------------------
3328| Facility : libnform
3329| Function : int _nc_Set_Form_Page(FORM * form,
3330| int page,
3331| FIELD * field)
3332|
3333| Description : Make the given page nr. the current page and make
3334| the given field the current field on the page. If
3335| for the field NULL is given, make the first field on
3336| the page the current field. The routine acts only
3337| if the requested page is not the current page.
3338|
3339| Return Values : E_OK - success
3340| != E_OK - error from subordinate call
3341+--------------------------------------------------------------------------*/
3342int
3343_nc_Set_Form_Page(FORM * form, int page, FIELD * field)
3344{
3345 int res = E_OK;
3346
3347 if ((form->curpage!=page))
3348 {
3349 FIELD *last_field, *field_on_page;
3350
3351 werase(Get_Form_Window(form));
3352 form->curpage = page;
3353 last_field = field_on_page = form->field[form->page[page].smin];
3354 do
3355 {
3356 if (field_on_page->opts & O_VISIBLE)
3357 if ((res=Display_Field(field_on_page))!=E_OK)
3358 return(res);

Callers 7

post_formFunction · 0.85
set_form_pageFunction · 0.85
PN_Next_PageFunction · 0.85
PN_Previous_PageFunction · 0.85
PN_First_PageFunction · 0.85
PN_Last_PageFunction · 0.85
set_current_fieldFunction · 0.85

Calls 3

weraseFunction · 0.85
_nc_Set_Current_FieldFunction · 0.85
FN_First_FieldFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…