static PRESULT nc_item_sel_callback(POBJECT_HEAD pObj, VEVENT event, UINT32 param1, UINT32 param2) { PRESULT ret = PROC_PASS; UINT8 bID = OSD_GetObjID(pObj); switch(event) { case EVN_POST_CHANGE: if(ID_CON_BACTIVE== bID) { newcamd_serinfo[current_index-1].bActive=param1; nc_item_sel_active(newcamd_serinfo[current_index-1].bActive,newcamd_serinfo[current_index-1].bAutouser,TRUE); } else if(ID_CON_BAUTOUSER== bID) { newcamd_serinfo[current_index-1].bAutouser=param1; nc_item_sel_autouser(newcamd_serinfo[current_index-1].bActive,newcamd_serinfo[current_index-1].bAutouser,TRUE); } else if(ID_CON_BDNS == bID) { newcamd_serinfo[current_index-1].bDNS_enable=param1; nc_item_sel_DNSenable(newcamd_serinfo[current_index-1].bDNS_enable,TRUE); } break; default: break; } return ret; }
static void nc_item_sel_active(UINT8 active,UINT8 bAuto,BOOL update) { UINT8 action ; UINT8 i; OSD_SetMultiselSel(&nc_item_selt1,active); action = ( active== 0) ? C_ATTR_INACTIVE : C_ATTR_ACTIVE; set_container_active(&nc_item_con1, action); set_container_active(&nc_item_con2, action); set_container_active(&nc_item_con3, action); set_container_active(&nc_item_con6, action); #if ((defined(ORDER_GZ1006005))||(defined(ORDER_GZ1006006))) set_container_active(&nc_item_con_type, action); #endif //set_container_active(&nc_item_con9, action);//auto user sel // action =( bAuto== 0 ||active==0) ? C_ATTR_INACTIVE : C_ATTR_ACTIVE; // set_container_active(&nc_item_con4, action);//user // set_container_active(&nc_item_con5, action);//pwd nc_item_sel_autouser(active,bAuto,FALSE); if(update) { OSD_DrawObject( (POBJECT_HEAD)&nc_item_con1, C_UPDATE_ALL); OSD_DrawObject( (POBJECT_HEAD)&nc_item_con2, C_UPDATE_ALL); OSD_DrawObject( (POBJECT_HEAD)&nc_item_con3, C_UPDATE_ALL); OSD_DrawObject( (POBJECT_HEAD)&nc_item_con4, C_UPDATE_ALL); OSD_DrawObject( (POBJECT_HEAD)&nc_item_con5, C_UPDATE_ALL); OSD_DrawObject( (POBJECT_HEAD)&nc_item_con6, C_UPDATE_ALL); #if ((defined(ORDER_GZ1006005))||(defined(ORDER_GZ1006006))) OSD_DrawObject( (POBJECT_HEAD)&nc_item_con_type, C_UPDATE_ALL); #endif //OSD_DrawObject( (POBJECT_HEAD)&nc_item_con9, C_UPDATE_ALL); OSD_TrackObject( (POBJECT_HEAD)&nc_item_con7, C_UPDATE_ALL); } }
static PRESULT nc_item_sel_callback(POBJECT_HEAD pObj, VEVENT event, UINT32 param1, UINT32 param2) { PRESULT ret = PROC_PASS; UINT8 bID = OSD_GetObjID(pObj); switch(event) { case EVN_POST_CHANGE: if(ID_CON_BACTIVE== bID) { newcamd_serinfo[current_index-1].bActive=param1; nc_item_sel_active(newcamd_serinfo[current_index-1].bActive,newcamd_serinfo[current_index-1].bAutouser,TRUE); } else if(ID_CON_BAUTOUSER== bID) { newcamd_serinfo[current_index-1].bAutouser=param1; nc_item_sel_autouser(newcamd_serinfo[current_index-1].bActive,newcamd_serinfo[current_index-1].bAutouser,TRUE); } else if(ID_CON_BDNS == bID) { newcamd_serinfo[current_index-1].bDNS_enable=param1; nc_item_sel_DNSenable(newcamd_serinfo[current_index-1].bDNS_enable,TRUE); } #if ((defined(ORDER_GZ1006005))||(defined(ORDER_GZ1006006))) else if(ID_CON_PROTOCOL==bID) { if(1==param1) newcamd_serinfo[current_index-1].reserv=2; else newcamd_serinfo[current_index-1].reserv=0; } #endif break; default: break; } return ret; }