doom3-gpl
Doom 3 GPL source release
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
PropTreeItemButton.h
Go to the documentation of this file.
1 #pragma once
2 
3 // PropTreeItemButton.h : header file
4 //
5 // Copyright (C) 1998-2001 Scott Ramsay
6 // sramsay@gonavi.com
7 // http://www.gonavi.com
8 //
9 // This material is provided "as is", with absolutely no warranty expressed
10 // or implied. Any use is at your own risk.
11 //
12 // Permission to use or copy this software for any purpose is hereby granted
13 // without fee, provided the above notices are retained on all copies.
14 // Permission to modify the code and to distribute modified code is granted,
15 // provided the above notices are retained, and a notice that the code was
16 // modified is included with the above copyright notice.
17 //
18 // If you use this code, drop me an email. I'd like to know if you find the code
19 // useful.
20 
21 #include "PropTreeItem.h"
22 
24 // CPropTreeItemButton window
25 
27 {
28 // Construction
29 public:
31  virtual ~CPropTreeItemButton();
32 
33 // Attributes
34 public:
35  // The non-attribute area needs drawing
36  virtual LONG DrawItem(CDC* pDC, const RECT& rc, LONG x, LONG y);
37 
38  // The attribute area needs drawing
39  virtual void DrawAttribute(CDC* pDC, const RECT& rc);
40 
41  // Retrieve the item's attribute value
42  virtual LPARAM GetItemValue();
43 
44  // Set the item's attribute value
45  virtual void SetItemValue(LPARAM lParam);
46 
47  // Overrideable - Returns TRUE if the point is on the button
48  virtual BOOL HitButton(const POINT& pt);
49 
50  void SetButtonText( LPCSTR text );
51 
52 protected:
53  CString buttonText;
54  CRect buttonRect;
55  CRect hitTestRect;
56  bool mouseDown;
57 
58 };
59 
61 
62 //{{AFX_INSERT_LOCATION}}
63 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
virtual BOOL HitButton(const POINT &pt)
Definition: PropTreeItem.h:58
virtual LONG DrawItem(CDC *pDC, const RECT &rc, LONG x, LONG y)
virtual void DrawAttribute(CDC *pDC, const RECT &rc)
GLenum GLint GLint y
Definition: glext.h:2849
#define PROPTREE_API
Definition: PropTree.h:53
GLenum GLint x
Definition: glext.h:2849
#define BOOL
Definition: mprintf.c:71
virtual LPARAM GetItemValue()
long LONG
virtual void SetItemValue(LPARAM lParam)