windows-custom-control-subclassing-20061212
[openafs.git] / src / WINNT / afsapplib / checklist.h
1 /*
2  * Copyright 2000, International Business Machines Corporation and others.
3  * All Rights Reserved.
4  * 
5  * This software has been released under the terms of the IBM Public
6  * License.  For details, see the LICENSE file in the top-level source
7  * directory or online at http://www.openafs.org/dl/license10.html
8  */
9
10 #ifndef CHECKLIST_H
11 #define CHECKLIST_H
12
13 /*
14  * DEFINITIONS ________________________________________________________________
15  *
16  */
17
18 #ifndef THIS_HINST
19 #define THIS_HINST  (HINSTANCE)GetModuleHandle(NULL)
20 #endif
21
22 #ifndef EXPORTED
23 #define EXPORTED
24 #endif
25
26
27 /*
28  * PROTOTYPES _________________________________________________________________
29  *
30  */
31
32 EXPORTED BOOL RegisterCheckListClass (void);
33
34 #define WC_CHECKLIST  TEXT("OpenAFS_CheckList")
35
36
37 #define LB_GETCHECK   (WM_USER+300)   // int iItem=wp  
38 #define LB_SETCHECK   (WM_USER+301)   // int iItem=wp, BOOL fChecked=lp
39
40 #define LBN_CLICKED   BN_CLICKED
41
42
43 /*
44  * BOOL LB_GetCheck (HWND hList, int iItem)
45  * void LB_SetCheck (HWND hList, int iItem, BOOL fCheck)
46  *
47  */
48 #define LB_GetCheck(_hList,_ii) \
49         SendMessage(_hList,LB_GETCHECK,(WPARAM)_ii,(LPARAM)0)
50 #define LB_SetCheck(_hList,_ii,_fCheck) \
51         SendMessage(_hList,LB_SETCHECK,(WPARAM)_ii,(LPARAM)_fCheck)
52
53
54 #endif
55