You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
kev/Drawer/Module/GeoSigmaDraw/InterfaceDisplayOrder.cpp

35 lines
712 B
C++

1 month ago
#include "stdafx.h"
#include "SigmaView.h"
#include "SectionDoc.h"
#include "ActionSortItem.h"
#include "ItemSelect.h"
//order:0=<3D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ 1=<3D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ 2=<3D><><EFBFBD><EFBFBD>һ<EFBFBD><D2BB> 3=<3D><><EFBFBD><EFBFBD>һ<EFBFBD><D2BB>
extern "C" __declspec(dllexport)
int DisplayOrder_Set(CSigmaView * pView, int order)
{
if (order < 0 || order >3)
return -1;
if (pView == NULL)
return -1;
if (pView->m_pDoc == NULL)
return -1;
CPositionList seletionSet;
pView->m_pDoc->GetSelectionSet(seletionSet);
CActionSortItem * pSortItem = 0;
if (order >= 0 && order <= 3)
{
pSortItem = new CActionSortItem(pView->m_pDoc, ID_OBJECT_MOVETOFRONT, seletionSet, order);
}
if (pSortItem != 0)
{
pView->m_pDoc->SetActionItem(pSortItem);
return 1;
}
return -1;
}