本文整理汇总了C++中BOARD_ITEM::GetList方法的典型用法代码示例。如果您正苦于以下问题:C++ BOARD_ITEM::GetList方法的具体用法?C++ BOARD_ITEM::GetList怎么用?C++ BOARD_ITEM::GetList使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BOARD_ITEM
的用法示例。
在下文中一共展示了BOARD_ITEM::GetList方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: RunActionPlugin
//.........这里部分代码省略.........
}
else
{
oldBuffer = GetScreen()->PopCommandFromUndoList();
wxASSERT( oldBuffer );
}
// Try do discover what was modified
PICKED_ITEMS_LIST deletedItemsList;
// Found deleted modules
for( unsigned int i = 0; i < oldBuffer->GetCount(); i++ )
{
BOARD_ITEM* item = (BOARD_ITEM*) oldBuffer->GetPickedItem( i );
ITEM_PICKER picker( item, UR_DELETED );
wxASSERT( item );
switch( item->Type() )
{
case PCB_NETINFO_T:
case PCB_MARKER_T:
case PCB_MODULE_T:
case PCB_TRACE_T:
case PCB_VIA_T:
case PCB_LINE_T:
case PCB_TEXT_T:
case PCB_DIMENSION_T:
case PCB_TARGET_T:
case PCB_SEGZONE_T:
// If item has a list it's mean that the element is on the board
if( item->GetList() == NULL )
{
deletedItemsList.PushItem( picker );
}
break;
case PCB_ZONE_AREA_T:
{
bool zoneFound = false;
for( int ii = 0; ii < currentPcb->GetAreaCount(); ii++ )
zoneFound |= currentPcb->GetArea( ii ) == item;
if( !zoneFound )
{
deletedItemsList.PushItem( picker );
}
break;
}
default:
wxString msg;
msg.Printf( _( "(PCB_EDIT_FRAME::OnActionPlugin) needs work: "
"BOARD_ITEM type (%d) not handled" ),
item->Type() );
wxFAIL_MSG( msg );
break;
}
}
// Mark deleted elements in undolist