#include <opcntr.h>
Inheritance diagram for ChangeContourToOuterAction:
Public Member Functions | |
ChangeContourToOuterAction () | |
Constructor for the action. | |
~ChangeContourToOuterAction () | |
virtual ActionCode | Execute () |
Executes the action. Causes a regen of all bevels nodes in the action's list. | |
Static Public Member Functions | |
static ActionCode | Init (Operation *pOp, ActionList *pActionList, NodeContourController *pContour, ChangeContourToOuterAction **NewAction) |
This is the function which creates an instance of this action. If there is no room in the undo buffer (which is determined by the base class Init function called within) the function will either return AC_NO_RECORD which means the operation can continue, but no undo information needs to be stored, or AC_OK which means the operation should continue AND record undo information. If the function returns AC_FAIL, there was not enough memory to record the undo information, and the user has decided not to continue with the operation. | |
Protected Attributes | |
NodeContourController * | m_pContour |
MILLIPOINT | m_LastWidth |
Definition at line 358 of file opcntr.h.
|
Constructor for the action.
Definition at line 1741 of file opcntr.cpp. 01742 { 01743 m_LastWidth = 0; 01744 01745 }
|
|
Definition at line 1838 of file opcntr.cpp.
|
|
Executes the action. Causes a regen of all bevels nodes in the action's list.
Reimplemented from Action. Definition at line 1811 of file opcntr.cpp. 01812 { 01813 ChangeContourToOuterAction * pNewAction = NULL; 01814 01815 // first, initialise an action to restore all the current widths in my list 01816 ActionCode Ac = ChangeContourToOuterAction::Init(pOperation, 01817 pOppositeActLst, 01818 m_pContour, 01819 &pNewAction); 01820 01821 Document * pDoc = Document::GetCurrent(); 01822 01823 if (Ac == AC_OK) 01824 { 01825 if (pDoc) 01826 pDoc->ForceRedraw(m_pContour->FindParentSpread(), m_pContour->GetBoundingRect(), FALSE, m_pContour); 01827 01828 m_pContour->SetWidth(m_LastWidth); 01829 m_pContour->RegenerateNode(NULL, FALSE); 01830 01831 if (pDoc) 01832 pDoc->ForceRedraw(m_pContour->FindParentSpread(), m_pContour->GetBoundingRect(), FALSE, m_pContour); 01833 } 01834 01835 return Ac; 01836 }
|
|
This is the function which creates an instance of this action. If there is no room in the undo buffer (which is determined by the base class Init function called within) the function will either return AC_NO_RECORD which means the operation can continue, but no undo information needs to be stored, or AC_OK which means the operation should continue AND record undo information. If the function returns AC_FAIL, there was not enough memory to record the undo information, and the user has decided not to continue with the operation.
Definition at line 1778 of file opcntr.cpp. 01782 { 01783 UINT32 ActSize = sizeof(ChangeContourToOuterAction); 01784 01785 ActionCode Ac = Action::Init(pOp,pActionList,ActSize,CC_RUNTIME_CLASS(ChangeContourToOuterAction),(Action**)ppNewAction); 01786 01787 if (Ac == AC_OK) 01788 { 01789 (*ppNewAction)->m_pContour = pController; 01790 (*ppNewAction)->m_LastWidth = pController->GetWidth(); 01791 } 01792 01793 return Ac; 01794 }
|
|
|
|
|