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


C++ AcDbVoidPtrArray::at方法代码示例

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


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

示例1: isModuleLoaded

bool isModuleLoaded(const char* str)
{
	AcDbVoidPtrArray* pApps = reinterpret_cast<AcDbVoidPtrArray*>(acrxLoadedApps());
	if (pApps==NULL)
		return false;
	bool bFound = false;
	for (int i=0;i<pApps->length();i++)
	{
		if (stricmp(reinterpret_cast<const char*>(pApps->at(i)),str)==0)
		{
			bFound = true;
			break;
		}
	}
	for (;pApps->length()>0;)
	{
		delete reinterpret_cast<char*>(pApps->at(0));
		pApps->removeAt(0);
	}
	delete pApps;
	return bFound;
}
开发者ID:kevinzhwl,项目名称:ObjectARXMod,代码行数:22,代码来源:SmileyUi.cpp

示例2: CreateBlock

AcDbObjectId CArxHelper::CreateBlock(const AcDbVoidPtrArray& arrEnt, const CString& strName)
{
	AcDbObjectId blockId = AcDbObjectId::kNull;
	AcDbBlockTableRecord* pBlockTableRecord = new AcDbBlockTableRecord();
	pBlockTableRecord->setName(strName);
	pBlockTableRecord->setOrigin(AcGePoint3d::kOrigin);
	for (int i = 0; i < arrEnt.length(); ++ i)
	{
		AcDbEntity* pEntity = (AcDbEntity*)arrEnt.at(i);
		pBlockTableRecord->appendAcDbEntity(pEntity);
		pEntity->close();
	}

	AcDbBlockTable* pBlockTable = NULL;
	acdbHostApplicationServices()->workingDatabase()->getSymbolTable(pBlockTable, AcDb::kForWrite);
	pBlockTable->add(blockId,pBlockTableRecord);
	pBlockTableRecord->close();
	pBlockTable->close();
	return blockId;
}
开发者ID:ninuo,项目名称:ArxWorkspace,代码行数:20,代码来源:ArxHelper2.cpp

示例3: addCmdTreeItem

BOOL
ArxDbgUiTdcCmds::OnInitDialog() 
{
    ArxDbgUiTdcRxObjectBase::OnInitDialog();

	buildCmdGroupMap();

    POSITION pos;
    CString str;
    AcDbVoidPtrArray* cmds = NULL;
    HTREEITEM treeItem;
	AcEdCommand* tmpCmd;
	bool isFirst = true;

    for (pos = m_cmdMap.GetStartPosition(); pos != NULL;) {
        m_cmdMap.GetNextAssoc(pos, str, (void*&)cmds);
 		treeItem = addCmdTreeItem(str, NULL, TVI_ROOT, true);
		if (treeItem != NULL) {
			int len = cmds->length();
			for (int i=0; i<len; i++) {
				tmpCmd = static_cast<AcEdCommand*>(cmds->at(i));
				addCmdTreeItem(tmpCmd->localName(), tmpCmd, treeItem, true);
			}

			if (isFirst) {
				m_cmdTree.SelectItem(treeItem);		// make first one selected
				isFirst = false;
			}
		}
   }

	buildColumns(m_dataList);
    displayCurrent();

    return TRUE;
}
开发者ID:kevinzhwl,项目名称:ObjectARXMod,代码行数:36,代码来源:ArxDbgUiTdcCmds.cpp


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