当前位置: 首页>>代码示例>>C++>>正文


C++ ODPoint::SetSelectNode方法代码示例

本文整理汇总了C++中ODPoint::SetSelectNode方法的典型用法代码示例。如果您正苦于以下问题:C++ ODPoint::SetSelectNode方法的具体用法?C++ ODPoint::SetSelectNode怎么用?C++ ODPoint::SetSelectNode使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ODPoint的用法示例。


在下文中一共展示了ODPoint::SetSelectNode方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: DeleteSelectablePoint

bool ODSelect::DeleteSelectablePoint( void *pdata, int SeltypeToDelete )
{
    SelectItem *pFindSel;

    if( NULL != pdata ) {
//    Iterate on the list
        wxSelectableItemListNode *node = pSelectList->GetFirst();

        while( node ) {
            pFindSel = node->GetData();
            if( pFindSel->m_seltype == SeltypeToDelete ) {
                if( pdata == pFindSel->m_pData1 ) {
                    delete pFindSel;
                    delete node;
                    g_pRolloverPoint = NULL;
                    
                    if( SELTYPE_ODPOINT == SeltypeToDelete ){
                        ODPoint *prp = (ODPoint *)pdata;
                        prp->SetSelectNode( NULL );
                    }
                    
                    return true;
                }
            }
            node = node->GetNext();
        }
    }
    return false;
}
开发者ID:Hakansv,项目名称:ocpn_draw_pi,代码行数:29,代码来源:ODSelect.cpp

示例2: DeleteAllSelectableTypePoints

bool ODSelect::DeleteAllSelectableTypePoints( int SeltypeToDelete )
{
    SelectItem *pFindSel;

//    Iterate on the list
    wxSelectableItemListNode *node = pSelectList->GetFirst();

    while( node ) {
        pFindSel = node->GetData();
        if( pFindSel->m_seltype == SeltypeToDelete ) {
            delete node;
            
            if( SELTYPE_ODPOINT == SeltypeToDelete ){
                ODPoint *prp = (ODPoint *)pFindSel->m_pData1;
                prp->SetSelectNode( NULL );
            }
            delete pFindSel;
            
            node = pSelectList->GetFirst();
            goto got_next_node;
        }

        node = node->GetNext();
        got_next_node: continue;
    }
    return true;
}
开发者ID:Hakansv,项目名称:ocpn_draw_pi,代码行数:27,代码来源:ODSelect.cpp

示例3: DeleteAllSelectableODPoints

bool ODSelect::DeleteAllSelectableODPoints( ODPath *pr )
{
    SelectItem *pFindSel;

//    Iterate on the select list
    wxSelectableItemListNode *node = pSelectList->GetFirst();

    while( node ) {
        pFindSel = node->GetData();
        if( pFindSel->m_seltype == SELTYPE_ODPOINT ) {
            ODPoint *ps = (ODPoint *) pFindSel->m_pData1;

            //    inner loop iterates on the path's point list
            wxODPointListNode *pnode = ( pr->m_pODPointList )->GetFirst();
            while( pnode ) {
                ODPoint *prp = pnode->GetData();

                if( prp == ps ) {
                    delete pFindSel;
                    pSelectList->DeleteNode( node );   //delete node;
                    prp->SetSelectNode( NULL );
                    
                    node = pSelectList->GetFirst();

                    goto got_next_outer_node;
                }
                pnode = pnode->GetNext();
            }
        }

        node = node->GetNext();
got_next_outer_node: continue;
    }
    return true;
}
开发者ID:Hakansv,项目名称:ocpn_draw_pi,代码行数:35,代码来源:ODSelect.cpp


注:本文中的ODPoint::SetSelectNode方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。