/* **************************************************
	wcDialogConstant.h
	Dialog 常量表
************************************************** */
#ifndef _WC_DIALOG_CONSTANT_H_
#define _WC_DIALOG_CONSTANT_H_

//主图形窗口、对话框及控件的ID
#define wdIdWalkMap	-99	//主图形窗口的ctrlId
#define wdIdStatic	-1	//静态文本的ctrlId
#define wdIdDialog	0	//对话框的ctrlId
#define wdIdOk		1	//对话框【确认】键的ctrlId
#define wdIdCancel	2	//对话框【取消】键的ctrlId
#define wdIdAbort	3	//对话框Windows默认的ctrlId
#define wdIdRetry   4
#define wdIdIgnore  5
#define wdIdYes     6
#define wdIdNo      7
#define wdIdClose   8
#define wdIdHelp    9

#define wdIdButton	110
#define wdIdCheck	120
#define wdIdRadio	130
#define wdIdEdit	140
#define wdIdListBox	150
#define wdIdComboBox 160
#define wdIdListCtrl 170

//对话框的控件类型
#define wdCtrlText		1	//static_text
#define wdCtrlEdit		2	//edit
#define wdCtrlButton	3	//button
#define wdCtrlCheck		4	//check button
#define wdCtrlRadio		5	//radio button
#define wdCtrlListBox	6	//list box
#define wdCtrlComboBox	7	//combo box
#define wdCtrlListCtrl	8	//list ctrl

//控件默认尺寸
#define wdSizeDefault	-1// static text default height8, width25
	// check button default height10
	// radio button default height10
	// edit default height12, width40
	// button default height14, width50

//对话框打开后，鼠标在主图形窗口活动的消息：
#define wdMapLbtnDown		1000
#define wdMapLbtnUp			1001
#define wdMapMouseMove		1002
#define wdMapRbtnDown		1003
#define wdMapRbtnUp			1004
#define wdMapLbtnDblclk		1005
#define wdMapRbtnDblclk		1006
#define wdMapFresh			1007

//对话框消息

#define wdMsgBnClicked	1//;//按钮(Button Notify)压下
#define wdMsgSelchange	2//;	//改变了ListBox当前选中项
						//改变了ComboBox当前选中项
						//改变了ListCtrl的当前item
#define wdMsgNmDblclk	3//;//在ListCtrl双击了鼠标
#define wdMsgEnKillFocus 4 //Edit Box失去焦点
#define wdMsgNmRclicked	5//;//在ListCtrl点击了鼠标右键

#define wdMsgNone		0	//无消息


//设置控件的状态
#define wdSwHide		0	//隐藏
#define wdSwShow		1	//显示
#define wdSwDisable		2	//置灰
#define wdSwEnable		3	//取消置灰
#define wdSwFocus		4	//设置焦点

//获取控件信息 getInfo(int ctrlId, int mask) 的 mask
#define wdMaskCtrlType		1	//获取控件类型: wdCtrlText,...,wdCtrlListCtrl
#define wdMaskHide			2	//是否 hide
#define wdMaskDisable		3	//是否 Disable
#define wdMaskReadOnly		4	//是否 ReadOnly
#define wdMaskItemCount		5	//for list item count
#define wdMaskColumnCount	6	//for list ctrl column count
#define wdMaskCtrlCount		7	//dialog ctrl count. ctrlId0
#define wdMaskCtrlHwndAt	8	//获取hWnd. 遍历控件：
	//	for(int at=getInfo(0,wdMaskCtrlCount); --at>0;)
	//		int hWnd=getInfo(at,wdMaskCtrlHwndAt);
#define wdMaskLeft			9	//获取控件矩形的左边界
#define wdMaskTop			10	//获取控件矩形的顶边界
#define wdMaskWidth			11	//获取控件矩形的宽
#define wdMaskHeight		12	//获取控件矩形的高
#define wdMaskHwnd			13	//获取控件句柄: m_hWnd=getInfo(ctrlId,wdMaskHwnd)
#define wdMaskCtrlId		14	//获取控件id: ctrlId=getInfo(hWnd,wdMaskCtrlId)

//
//添加控件时的扩展式样（与MFC同）
//
// * Window Styles
#define WS_BORDER           0x00800000
#define WS_VSCROLL          0x00200000
#define WS_HSCROLL          0x00100000
#define WS_THICKFRAME       0x00040000
#define WS_GROUP            0x00020000
#define WS_TABSTOP          0x00010000
#define WS_EX_STATICEDGE    0x00020000

// * Static Control Constants
#define SS_LEFT             0x0000
#define SS_CENTER           0x0001
#define SS_RIGHT            0x0002
#define SS_ICON             0x0003
#define SS_BLACKRECT        0x0004
#define SS_GRAYRECT         0x0005
#define SS_WHITERECT        0x0006
#define SS_BLACKFRAME       0x0007
#define SS_GRAYFRAME        0x0008
#define SS_WHITEFRAME       0x0009
#define SS_SIMPLE           0x000B
#define SS_LEFTNOWORDWRAP   0x000C
#define SS_ETCHEDHORZ       0x0010
#define SS_ETCHEDVERT       0x0011
#define SS_ETCHEDFRAME      0x0012
#define SS_NOPREFIX         0x0080
#define SS_NOTIFY           0x0100
#define SS_RIGHTJUST        0x0400
#define SS_SUNKEN           0x1000
#define SS_CENTERIMAGE      0x00000200

// * Edit Control Styles
#define ES_LEFT             0x0000
#define ES_CENTER           0x0001
#define ES_RIGHT            0x0002
#define ES_MULTILINE        0x0004
#define ES_UPPERCASE        0x0008
#define ES_LOWERCASE        0x0010
#define ES_PASSWORD         0x0020
#define ES_AUTOVSCROLL      0x0040
#define ES_AUTOHSCROLL      0x0080
#define ES_NOHIDESEL        0x0100
#define ES_READONLY         0x0800
#define ES_WANTRETURN       0x1000
#define ES_NUMBER           0x2000

// * Button Control Styles
#define BS_DEFPUSHBUTTON    0x0001
#define BS_AUTOCHECKBOX     0x0003
#define BS_3STATE           0x0005
#define BS_AUTO3STATE       0x0006
#define BS_GROUPBOX         0x0007
#define BS_AUTORADIOBUTTON  0x0009
#define BS_LEFTTEXT         0x0020
#define BS_LEFT             0x0100
#define BS_RIGHT            0x0200
#define BS_CENTER           0x0300
#define BS_TOP              0x0400
#define BS_BOTTOM           0x0800
#define BS_VCENTER          0x0C00
#define BS_PUSHLIKE         0x1000
#define BS_MULTILINE        0x2000
#define BS_NOTIFY           0x4000
#define BS_FLAT             0x8000

// * Listbox Styles
#define LBS_SORT              0x0002
#define LBS_MULTIPLESEL       0x0008
#define LBS_USETABSTOPS       0x0080
#define LBS_NOINTEGRALHEIGHT  0x0100
#define LBS_MULTICOLUMN       0x0200
#define LBS_WANTKEYBOARDINPUT 0x0400
#define LBS_DISABLENOSCROLL   0x1000
#define LBS_NOSEL             0x4000

// * Combo Box styles
#define CBS_SIMPLE            0x0001
#define CBS_DROPDOWN          0x0002
#define CBS_DROPDOWNLIST      0x0003
#define CBS_AUTOHSCROLL       0x0040
#define CBS_SORT              0x0100
#define CBS_HASSTRINGS        0x0200
#define CBS_NOINTEGRALHEIGHT  0x0400
#define CBS_DISABLENOSCROLL   0x0800
#define CBS_UPPERCASE         0x2000
#define CBS_LOWERCASE         0x4000

// * ListView styles
#define LVS_SINGLESEL         0x0004
#define LVS_SHOWSELALWAYS     0x0008
#define LVS_SORTASCENDING     0x0010
#define LVS_SORTDESCENDING    0x0020
#define LVS_NOLABELWRAP       0x0080
#define LVS_AUTOARRANGE       0x0100
#define LVS_EDITLABELS        0x0200
#define LVS_NOSCROLL          0x2000
#define LVS_ALIGNTOP          0x0000
#define LVS_ALIGNLEFT         0x0800
#define LVS_NOCOLUMNHEADER    0x4000
#define LVS_NOSORTHEADER      0x8000
// 用于 addCtrl 中的 LVS_EX
#define LVS_EX_GRIDLINES      0x0001
#define LVS_EX_CHECKBOXES     0x0004
#define LVS_EX_FULLROWSELECT  0x0020
#define LVS_EX_INFOTIP        0x0400

//列表控件listCtrl的列对齐
#define LVCFMT_LEFT			0
#define LVCFMT_RIGHT		1
#define LVCFMT_CENTER		2

#endif //_WC_DIALOG_CONSTANT_H_
