#ifndef _varext_h
#define _varext_h

#include "string.h"
#include "memory.h"
#include "stdafx.h"
#include "BkgPic.h"

//From	Dm
_declspec(dllimport) unsigned char DmCurLayer;
_declspec(dllimport) unsigned char DmCurLtype;
_declspec(dllimport) unsigned char DmCurColor;
_declspec(dllimport) double	   DmPickValve;
_declspec(dllimport) double	   DmEnlargeScale;	  //局部放大的比例系数
_declspec(dllimport) int	   DmScreenPickValve;		  //系统拾取盒的象素边长
_declspec(dllimport) int	   EyeFlag;
_declspec(dllimport) double	  *DmWinCenterX;
_declspec(dllimport) double	  *DmWinCenterY;
_declspec(dllimport) int	  *DmScreenWidth;
_declspec(dllimport) int	  *DmScreenHeight;

_declspec(dllimport) unsigned char DmGndColor;
_declspec(dllimport) int	   DmPickColor;
_declspec(dllimport) BOOL	   DmSetXOR;
_declspec(dllimport) int	   DmDefaultLineStyleCount;
_declspec(dllimport) int	   DmDefaultLayerCount;
_declspec(dllimport) CDC	  *dmDC;
_declspec(dllimport) CDC	  *exbDC;
_declspec(dllimport) BOOL	   DmUseCDC;

// Lg 2004-8-3 add for  鼠标形状
_declspec(dllimport) BOOL g_bIsPick;
_declspec(dllimport) BOOL g_bCommandIsOver;
_declspec(dllimport) BOOL g_bFirstPickOver;
_declspec(dllimport) BOOL g_bIsFirst;



//From	M2d
_declspec(dllimport) double M2dLeftDownX,M2dLeftDownY,M2dRightUpX,M2dRightUpY;
_declspec(dllimport) int    M2dSymetry;
_declspec(dllimport) double M2dScalex;
_declspec(dllimport) double M2dScaley;
_declspec(dllimport) double M2dAngle;
_declspec(dllimport) double M2dMirrorAngle;
_declspec(dllimport) double M2dMatrix[3][3];
_declspec(dllimport) double M2dCalPre;

//From	Ui
_declspec(dllimport) BOOL	AdmFirstFlag;
_declspec(dllimport) int	uiPickStatus;
_declspec(dllimport) int	uiMapCommandID;
_declspec(dllimport) int	uiSnapMode;
_declspec(dllimport) BOOL	uiPickMode;
_declspec(dllimport) BOOL	uiIsWinNT;
_declspec(dllimport) BOOL	uiDragPrompt;
_declspec(dllimport) BOOL	uiIsPickObject;
_declspec(dllimport) BOOL	uiModChange;

_declspec(dllimport) int	MenuChoice;
_declspec(dllimport) int       *pMenuChoice;

//From	Sys
_declspec(dllimport) double	  SysPaperScale;
_declspec(dllimport) double	  SysPaperWidth;
_declspec(dllimport) double	  SysPaperHeight;
_declspec(dllimport) short	  SysPaperDirect; //图纸放置方式(横或竖)
_declspec(dllimport) int	  SysPaperSizeIndex;

_declspec(dllimport) BOOL	SysPtMarkOnScreen; // TRUE == there is a X mark on screen
_declspec(dllimport) BOOL	SysCursorOnScreen;
_declspec(dllimport) BOOL	SysCursorSwitch;
_declspec(dllimport) int	SysSnapMask;
_declspec(dllimport) int	SysPickMask;
_declspec(dllimport) CString	SysCurrentFileName;
_declspec(dllimport) BOOL	SysCurrentOnlyRead;//dbf 2004.1.18 文件是否只读 ture-只读
_declspec(dllimport) LONG		SysSaveVersion;

_declspec(dllimport) BOOL	SysShowGrid;	  //栅格点显示开关
_declspec(dllimport) double	SysGridDistance;		  //栅格点距离
_declspec(dllimport) POINT	SysCursorPoint;
_declspec(dllimport) int	UcsNumber; //用户坐标系的数量
_declspec(dllimport) int	UcsHideFlag;
_declspec(dllimport) int	SysCurUcs;

_declspec(dllimport) BOOL	TriGuideLineFlag;	  //判断是否处于三视图导航
_declspec(dllimport) int	GuideType;		   // 0,1,2,3,4分四种情况判断,考虑斜率(全局),光标位置,(点区)
_declspec(dllimport) BOOL	SaveEyeFlag;

_declspec(dllimport) char	CaxPathName[256];

_declspec(dllimport) char	SysInputByKeyBoard;
_declspec(dllimport) double	SysInputX;
_declspec(dllimport) double	SysInputY;

_declspec(dllimport) int  SysGndColor;
_declspec(dllimport) int  SysCoorColor;
_declspec(dllimport) int  SysUserCoorColor;
_declspec(dllimport) int  SysCursorColor;
_declspec(dllimport) int  SysDragColor;
_declspec(dllimport) int  SysGridColor;
_declspec(dllimport) int  SysGuideColor;
_declspec(dllimport) int  SysSmartColor;
_declspec(dllimport) int  SysCurPtColor;

_declspec(dllimport) long	SysSaveTime;
_declspec(dllimport) long	SysInqPre;

_declspec(dllimport) double	SysMaxReal;
_declspec(dllimport) double	SysLimitReal;
_declspec(dllimport) int	SysVideoMode;
_declspec(dllimport) CString	SysAutoLoadFile;
_declspec(dllimport) CString	SysFilePathName;
_declspec(dllimport) CString	SysHelpFileName;
_declspec(dllimport) CString	SysDefaultSHXPath; //PQ Add 2004,5,28 形文件的缺省路径

//{{{孙永忠增加于2000.07.19，在系统配置对话框中设置
_declspec(dllimport) CString g_sTitlePanelStyleName;	//标题栏字型
_declspec(dllimport) CString g_sTitleBlockStyleName;	//明细表字型
_declspec(dllimport) CString g_sSeriNumStyleName;		//零件序号字型
_declspec(dllimport) CString g_sSpareCFont;				//中文备用字体
_declspec(dllimport) CString g_sSpareEFont;				//西文备用字体
_declspec(dllimport) CString g_sSpareCFont1;				//中文备用字体
_declspec(dllimport) CString g_sSpareEFont1;				//西文备用字体
//}}}

_declspec(dllimport) BOOL	SysPasteFromFile;
_declspec(dllimport) BOOL	SysEnablePasteFromFile;
_declspec(dllimport) BOOL	SysCutEnt;
_declspec(dllimport) BOOL	SysCopyToClip;

_declspec(dllimport) BOOL	SysDispPrompt;
_declspec(dllimport) double	minWinLen;
_declspec(dllimport) double	maxWinLen;

_declspec(dllimport) int	SysRKeyActive;
_declspec(dllimport) int	SysPrePointType;
_declspec(dllimport) int	SysCurPointType;
_declspec(dllimport) int	SystoolPointStatus;

_declspec(dllimport) double	 Adm_Ucs_X;
_declspec(dllimport) double	 Adm_Ucs_Y; //当前用户坐标系同系统坐标系的偏移距离
_declspec(dllimport) double	 Adm_Ucs_Ang;	    //当前用户坐标系旋转角
_declspec(dllimport) double	 Adm_Csa;
_declspec(dllimport) double	 Adm_Sna;
_declspec(dllimport) long	 AdmSaveTime;

//1998-09-15    CurrentVersion = 1000   (CurrentVersion/1000)
//1998-10-15	CurrentVersion = 1010;
//1999-06-30	CurrentVersion = 1020;
_declspec(dllimport) LONG	 CurrentVersion;

//2002-1-14	CappVersion = 8010;  syc
_declspec(dllimport) LONG	 CappVersion;

_declspec(dllimport) BOOL   IsEb97File;
_declspec(dllimport) BOOL   IsLoginSuccess;

_declspec(dllimport) BOOL  IsOpenFile;
_declspec(dllimport) BOOL  IsSaveFilePwd;
_declspec(dllimport) BOOL  IsEnableSetPwd;
_declspec(dllimport) CString   SysOpenExbFilePwd;
_declspec(dllimport) CString   SysEditExbFilePwd;
_declspec(dllimport) BOOL  IsCorrectPwd;
_declspec(dllimport) BOOL  IsCheckPwd;
_declspec(dllimport) int   OpenOrEditRights;	//0==>open, 1==>edit, 2==>both
_declspec(dllimport) CString   SysAttribInfo;

_declspec(dllimport) BOOL  IsAutoLayer;
_declspec(dllimport) BOOL  IsAutoSaveBakFile;
_declspec(dllimport) BOOL  IsTextSizeFixed;
_declspec(dllimport) BOOL  IsOldTextRotate;
_declspec(dllimport) BOOL  IsOleServer;
_declspec(dllimport) BOOL  IsExplodeBlock;
_declspec(dllimport) BOOL  SysAttFilter;

//capp
_declspec(dllimport) BOOL  IsTemplateStatus;
_declspec(dllimport) BOOL  ShiftLButtonDown;
_declspec(dllimport) BOOL  ShiftRButtonDown;
_declspec(dllimport) BOOL  CtrlLButtonDown;
_declspec(dllimport) BOOL  CtrlRButtonDown;

_declspec(dllimport) BOOL  IsWriteCell;
_declspec(dllimport) BOOL  IsWriteTable;
_declspec(dllimport) BOOL  IsCopyBlock;

_declspec(dllimport) BOOL  TemIsModified;
_declspec(dllimport) BOOL  CardIsModified;

//for capp
_declspec(dllimport) double	  SysBackPaperScale;
_declspec(dllimport) double	  SysBackPaperWidth;
_declspec(dllimport) double	  SysBackPaperHeight;
_declspec(dllimport) short	  SysBackPaperDirect; //图纸放置方式(横或竖)
_declspec(dllimport) int      SysBackPaperSizeIndex;
_declspec(dllimport) CString   DmColumnFields;
_declspec(dllimport) int      DmPickField;

_declspec(dllimport) CString   ReguName;  //工艺规程名称
_declspec(dllimport) CString   ReguNo;    //工艺规程编号
_declspec(dllimport) CString   ReguFileNo; //工艺文件编号
_declspec(dllimport) CString	  CappCardTempName;

_declspec(dllimport) long	  AdmCardSaveTime;

_declspec(dllimport) int uiNoMemoryError();
//hsb
_declspec(dllimport) unsigned char	g_cFileReadGndColor;
_declspec(dllimport) BOOL			g_bEditCommand;
_declspec(dllimport) int			g_iMinUnitOfTextDisplay;
//
_declspec(dllimport) BOOL			SysIsLargeCursor;
_declspec(dllimport) BOOL			SysIsDisplayViewFrame; //显示视图边框
_declspec(dllimport) BOOL			SysIsParasolidInit;	//是否初始化parasolid平台
_declspec(dllimport) BOOL			SysRead3dInfo;		///dmEntListSerialize函数打开文件时候是否处理3d信息
_declspec(dllimport) BOOL			SysUpdate3dView; 



//_declspec(dllimport) CBkgPicInfo	SysBkgPicInfo;	// Zwz 2001-4-23
_declspec(dllimport) double		SysBkPicScale;
_declspec(dllimport) double		SysBkPicInsertX;
_declspec(dllimport) double		SysBkPicInsertY;
_declspec(dllimport) int		SysBkPicPixWidth;
_declspec(dllimport) int		SysBkPicPixHeight;
_declspec(dllimport) double		SysBkPicRealWidth;
_declspec(dllimport) double		SysBkPicRealHeight;
_declspec(dllimport) CString	SysBkPicPath;
_declspec(dllimport) int		SysBkPicBitCount;


_declspec(dllimport) LPVOID			SysLpBits;	// Zwz 2001-4-29
//_declspec(dllimport) HBITMAP		SysHBkgPic;// Zwz 2001-4-29
;// WZH 2001-6-8
_declspec(dllimport) CString SysListDataFile;
_declspec(dllimport) CString SysListDataTable;
_declspec(dllimport) BOOL SysListDataIsUpdate;
_declspec(dllimport) CStringArray PostilFileArray;
_declspec(dllimport) BOOL IsAutoOpenPostil;
//WZH
_declspec(dllimport) BOOL bTeamVaultServerIsExist;// WZH 2002.1.10
//tzg		2002.3.14
_declspec(dllimport) int WinSystem;

#endif



//End varext.h Define
