📄 stdafx.h
字号:
// stdafx.h : include file for standard system include files,
// or project specific include files that are used frequently, but
// are changed infrequently
//
#if !defined(AFX_STDAFX_H__B2D61027_19A4_4163_B02C_C099DF9B0115__INCLUDED_)
#define AFX_STDAFX_H__B2D61027_19A4_4163_B02C_C099DF9B0115__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#define VC_EXTRALEAN // Exclude rarely-used stuff from Windows headers
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
#include <afxtempl.h>
#include <afxsock.h>
#include <afxole.h> // MFC OLE classes
#include <AfxMt.h>
#include <MMSYSTEM.H>
#include <digitalv.h>
#include "math.h"
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
#ifdef _AFXDLL
#pragma comment(lib,"winmm.lib")
#endif
#endif // _AFX_NO_AFXCMN_SUPPORT
#include "stdlib.h"
#include "lib\cg200-32.h"
#include "lib\MemAlloc.h"
#include "lib\RecCtl.h"
#include "lib\GCommDef.h"
#include "lib\ViewCtl.h"
#include "lib\MPJ.H"
#include "lib\GCommDef.H"
#include "ImageLoad.h"
#include "DeviceMgr.h"
#define _CHANNEL_NUM 8
#define _CONTROL_START 1
#define _CONTROL_STOP 2
#include "Public.h"
#pragma comment(lib,"lib/ImageLoad.lib")
#pragma comment(lib,"lib/cg200d32.lib")
#pragma comment(lib,"lib/memalloc.lib")
#pragma comment(lib,"lib/recctl.lib")
#pragma comment(lib,"lib/viewctl.lib")
#pragma comment(lib,"lib/Hooksdll.lib")
extern DWORD g_dwNumberOfSlots;
extern BOOL g_bSlotOpened[_MAX_SLOT_NUMBER];
extern CDeviceObject* g_pDevice[_MAX_SLOT_NUMBER];
extern int g_RGBColorBits;
extern CString g_sZoneType[9];
/////////////////////////////////////////////////////
//
typedef struct _GV_ITEM
{
int row,col; // Row and Column of item
UINT mask; // Mask for use in getting/setting cell data
UINT state; // cell state (focus/hilighted etc)
UINT nFormat; // Format of cell
CString szText; // Text in cell
int iImage; // index of the list view item抯 icon
COLORREF crBkClr; // Background colour (or CLR_DEFAULT)
COLORREF crFgClr; // Forground colour (or CLR_DEFAULT)
LPARAM lParam; // 32-bit value to associate with item
LOGFONT lfFont; // Cell font
UINT nEditFormat;
} GV_ITEM;
////////////////////////////////////////////////
//
typedef struct tagNM_GRIDVIEW
{
NMHDR hdr;
int iRow;
int iColumn;
CPrintInfo *pInfo;
CDC *pDC;
BOOL bValid;
CString sTxt;
} NM_GRIDVIEW;
// 网格线选择
#define GVL_NONE 0
#define GVL_HORZ 1
#define GVL_VERT 2
#define GVL_BOTH 3
// 单元数据掩码
#define GVIF_TEXT LVIF_TEXT
#define GVIF_IMAGE LVIF_IMAGE
#define GVIF_PARAM LVIF_PARAM
#define GVIF_STATE LVIF_STATE
#define GVIF_BKCLR (GVIF_STATE<<1)
#define GVIF_FGCLR (GVIF_STATE<<2)
#define GVIF_FORMAT (GVIF_STATE<<3)
#define GVIF_FONT (GVIF_STATE<<4)
// 单元状态
#define GVIS_FOCUSED 0x0001
#define GVIS_SELECTED 0x0002
#define GVIS_DROPHILITED 0x0004
#define GVIS_READONLY 0x0008
// 单元查询选择
#define GVNI_FOCUSED 0x0001
#define GVNI_SELECTED 0x0002
#define GVNI_DROPHILITED 0x0004
#define GVNI_READONLY 0x0008
#define GVNI_ABOVE LVNI_ABOVE
#define GVNI_BELOW LVNI_BELOW
#define GVNI_TOLEFT LVNI_TOLEFT
#define GVNI_TORIGHT LVNI_TORIGHT
#define GVNI_ALL (LVNI_BELOW|LVNI_TORIGHT)
// 点击测试
#define GVHT_DATA 0x0000
#define GVHT_TOPLEFT 0x0001
#define GVHT_COLHDR 0x0002
#define GVHT_ROWHDR 0x0004
#define GVHT_COLSIZER 0x0008
#define GVHT_ROWSIZER 0x0010
#define GVHT_LEFT 0x0020
#define GVHT_RIGHT 0x0040
#define GVHT_ABOVE 0x0080
#define GVHT_BELOW 0x0100
// 网格发给父窗口的消息
#define GVN_BEGINDRAG LVN_BEGINDRAG // LVN_FIRST-9
#define GVN_BEGINLABELEDIT LVN_BEGINLABELEDIT // LVN_FIRST-5
#define GVN_BEGINRDRAG LVN_BEGINRDRAG
#define GVN_COLUMNCLICK LVN_COLUMNCLICK
#define GVN_DELETEITEM LVN_DELETEITEM
#define GVN_ENDLABELEDIT LVN_ENDLABELEDIT // LVN_FIRST-6
#define GVN_SELCHANGING LVN_BEGINLABELEDIT+1 // LVN_FIRST-4
#define GVN_SELCHANGED LVN_BEGINLABELEDIT+2 // LVN_FIRST-3
#define GVN_PRINT_HEADER LVN_BEGINLABELEDIT+3
#define GVN_PRINT_FOOT LVN_BEGINLABELEDIT+4
#define GVN_CELL_CHECK LVN_BEGINLABELEDIT+5
#define GVN_CELL_SAVE LVN_BEGINLABELEDIT+6
#define GVN_ROW_SAVE LVN_BEGINLABELEDIT+7
#define GVN_ROW_CHECK LVN_BEGINLABELEDIT+8
#define GVN_HEADER_CHECK LVN_BEGINLABELEDIT+9
#define GVN_HEADER_SAVE LVN_BEGINLABELEDIT+10
#define GVN_ROW_CLICK LVN_BEGINLABELEDIT+11
#define GVN_ROW_DBCLICK LVN_BEGINLABELEDIT+12
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_STDAFX_H__B2D61027_19A4_4163_B02C_C099DF9B0115__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -