Files
envi-code/SourceCode/Code2026/tg_shs/shs_TwtAnotate/TLeaderAddOtherPtJig.cpp
T
gjm 164968b62e chore
把非utf8-bom编码的cpp/h文件改为 utf8 bom 编码, msvc识别utf8编码时,如果不是bom格式的,会使用当前cp_oem来解码.
2026-10-04 00:04:20 +08:00

59 lines
1.4 KiB
C++

// TLeaderAddOtherPtJig.cpp: implementation of the CTLeaderAddOtherPtJig class.
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "TLeaderAddOtherPtJig.h"
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
TLeaderAddOtherPtJig::TLeaderAddOtherPtJig(CLeaderTextDlg *pDlg, XPoint ptStart, XPoint ptBase)
:m_pDlg(pDlg)
{
m_bUpdateDlg = TRUE;
m_ptLeader = ptBase.AsAcGePoint3d();
m_ptFirstVertexes = ptStart.AsAcGePoint3d();
m_line.setStartPoint(m_ptLeader);
}
TLeaderAddOtherPtJig::TLeaderAddOtherPtJig(BOOL bAllPtsOnLine, XPoint ptStart, XPoint ptBase,double dLayoutRotation,BOOL b)
{
m_bUpdateDlg = FALSE;
m_ptLeader = ptBase.AsAcGePoint3d();
m_ptFirstVertexes = ptStart.AsAcGePoint3d();
m_line.setStartPoint(m_ptLeader);
m_nLayoutRotation = dLayoutRotation;
m_bLeaderParall = b;
}
// 开始执行拖动
int TLeaderAddOtherPtJig::DoIt(int *keyIndex)
{
// XPushVar<int> osmode(_T("OSMODE"), 0); // 临时将对象捕捉关掉
return TSymbEdJig::DoIt(keyIndex);
}
AcEdJig::DragStatus TLeaderAddOtherPtJig::GetPoint(XPoint &pt)
{
return acquirePoint(pt); // 自由拖拽,不受正交控制
}
Adesk::Boolean TLeaderAddOtherPtJig::update()
{
if (m_bUpdateDlg) // 时时更新对话框
{
m_pDlg->UpdateData(TRUE);
}
m_line.setEndPoint(m_ptResult);
return Adesk::kTrue;
}
AcDbEntity* TLeaderAddOtherPtJig::entity() const
{
return (AcDbEntity *)&m_line;
}