#include "stdafx.h" #include "SigmaView.h" #include "SectionDoc.h" #include "ItemCurveProcess.h" static CItemCurveProcess * GetItemCloseCurveFromView(CSigmaView * pView) { if (pView == NULL) return 0; CItem * item = pView->GetItem(); if (item == NULL) return 0; CItemCurveProcess * itemCurveProcess = dynamic_cast(item); if (itemCurveProcess == NULL) return 0; return itemCurveProcess; } extern "C" __declspec(dllexport) int ItemCurveProcess_SetType(CSigmaView* pView, int type) { CItemCurveProcess * itemCurveProcess = GetItemCloseCurveFromView(pView); if (itemCurveProcess == NULL) return -1; return itemCurveProcess->SetProcessIdea(type); } extern "C" __declspec(dllexport) int ItemCurveProcess_GetResult(CSigmaView* pView) { CItemCurveProcess * itemCurveProcess = GetItemCloseCurveFromView(pView); if (itemCurveProcess == NULL) return -1; return itemCurveProcess->GetProcessResult(); }