| OLD | NEW |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #ifndef _PWL_WND_H_ | 7 #ifndef _PWL_WND_H_ |
| 8 #define _PWL_WND_H_ | 8 #define _PWL_WND_H_ |
| 9 | 9 |
| 10 class IPWL_Provider; | 10 class IPWL_Provider; |
| 11 class CPWL_Wnd; | 11 class CPWL_Wnd; |
| 12 class CPWL_MsgControl; | 12 class CPWL_MsgControl; |
| 13 class CPWL_Wnd; | 13 class CPWL_Wnd; |
| 14 class CPWL_ScrollBar; | 14 class CPWL_ScrollBar; |
| 15 class CPWL_Timer; | 15 class CPWL_Timer; |
| 16 class CPWL_TimerHandler; | 16 class CPWL_TimerHandler; |
| 17 class IPWL_SpellCheck; | 17 class IPWL_SpellCheck; |
| 18 class IFX_SystemHandler; | 18 class IFX_SystemHandler; |
| 19 | 19 |
| 20 #ifdef FX_READER_DLL | 20 #ifdef FX_READER_DLL |
| 21 » #ifdef PWL_EXPORT | 21 #ifdef PWL_EXPORT |
| 22 » » » #define PWL_CLASS» » __declspec(dllexport) | 22 #define PWL_CLASS __declspec(dllexport) |
| 23 » » » #define PWL_FUNCTION» PWL_CLASS» | 23 #define PWL_FUNCTION PWL_CLASS |
| 24 » » #else | |
| 25 » » » #define PWL_CLASS | |
| 26 » » » #define PWL_FUNCTION | |
| 27 » #endif | |
| 28 #else | 24 #else |
| 29 » #define PWL_CLASS | 25 #define PWL_CLASS |
| 30 » #define PWL_FUNCTION | 26 #define PWL_FUNCTION |
| 31 #endif | 27 #endif |
| 32 | 28 #else |
| 33 //window styles | 29 #define PWL_CLASS |
| 34 #define PWS_CHILD» » » » » » » 0x800000
00L | 30 #define PWL_FUNCTION |
| 35 #define PWS_BORDER» » » » » » » 0x400000
00L | 31 #endif |
| 36 #define PWS_BACKGROUND» » » » » » 0x20000000L | 32 |
| 37 #define PWS_HSCROLL» » » » » » » 0x100000
00L | 33 // window styles |
| 38 #define PWS_VSCROLL» » » » » » » 0x080000
00L | 34 #define PWS_CHILD 0x80000000L |
| 39 #define PWS_VISIBLE» » » » » » » 0x040000
00L | 35 #define PWS_BORDER 0x40000000L |
| 40 #define PWS_DISABLE» » » » » » » 0x020000
00L | 36 #define PWS_BACKGROUND 0x20000000L |
| 41 #define PWS_READONLY» » » » » » 0x01000000L | 37 #define PWS_HSCROLL 0x10000000L |
| 42 #define PWS_AUTOFONTSIZE» » » » » 0x00800000L | 38 #define PWS_VSCROLL 0x08000000L |
| 43 #define PWS_AUTOTRANSPARENT» » » » » 0x00400000L | 39 #define PWS_VISIBLE 0x04000000L |
| 44 #define PWS_NOREFRESHCLIP» » » » » 0x00200000L | 40 #define PWS_DISABLE 0x02000000L |
| 45 | 41 #define PWS_READONLY 0x01000000L |
| 46 //edit and label styles | 42 #define PWS_AUTOFONTSIZE 0x00800000L |
| 47 #define PES_MULTILINE» » » » » » 0x0001L | 43 #define PWS_AUTOTRANSPARENT 0x00400000L |
| 48 #define PES_PASSWORD» » » » » » 0x0002L | 44 #define PWS_NOREFRESHCLIP 0x00200000L |
| 49 #define PES_LEFT» » » » » » » 0x0004L | 45 |
| 50 #define PES_RIGHT» » » » » » » 0x0008L | 46 // edit and label styles |
| 51 #define PES_MIDDLE» » » » » » » 0x0010L | 47 #define PES_MULTILINE 0x0001L |
| 52 #define PES_TOP»» » » » » » » 0x0020L | 48 #define PES_PASSWORD 0x0002L |
| 53 #define PES_BOTTOM» » » » » » » 0x0040L | 49 #define PES_LEFT 0x0004L |
| 54 #define PES_CENTER» » » » » » » 0x0080L | 50 #define PES_RIGHT 0x0008L |
| 55 #define PES_CHARARRAY» » » » » » 0x0100L | 51 #define PES_MIDDLE 0x0010L |
| 56 #define PES_AUTOSCROLL» » » » » » 0x0200L | 52 #define PES_TOP 0x0020L |
| 57 #define PES_AUTORETURN» » » » » » 0x0400L | 53 #define PES_BOTTOM 0x0040L |
| 58 #define PES_UNDO» » » » » » » 0x0800L | 54 #define PES_CENTER 0x0080L |
| 59 #define PES_RICH» » » » » » » 0x1000L | 55 #define PES_CHARARRAY 0x0100L |
| 60 #define PES_SPELLCHECK» » » » » » 0x2000L | 56 #define PES_AUTOSCROLL 0x0200L |
| 61 #define PES_TEXTOVERFLOW» » » » » 0x4000L | 57 #define PES_AUTORETURN 0x0400L |
| 62 #define PES_NOREAD» » » » » » » 0x8000L | 58 #define PES_UNDO 0x0800L |
| 63 | 59 #define PES_RICH 0x1000L |
| 64 //listbox styles | 60 #define PES_SPELLCHECK 0x2000L |
| 65 #define PLBS_MULTIPLESEL» » » » » 0x0001L | 61 #define PES_TEXTOVERFLOW 0x4000L |
| 66 #define PLBS_HOVERSEL» » » » » » 0x0008L | 62 #define PES_NOREAD 0x8000L |
| 67 | 63 |
| 68 //combobox styles | 64 // listbox styles |
| 69 #define PCBS_ALLOWCUSTOMTEXT» » » » 0x0001L | 65 #define PLBS_MULTIPLESEL 0x0001L |
| 70 | 66 #define PLBS_HOVERSEL 0x0008L |
| 71 //richedit styles | 67 |
| 72 #define PRES_MULTILINE» » » » » » 0x0001L | 68 // combobox styles |
| 73 #define PRES_AUTORETURN»» » » » » 0x0002L | 69 #define PCBS_ALLOWCUSTOMTEXT 0x0001L |
| 74 #define PRES_AUTOSCROLL»» » » » » 0x0004L | 70 |
| 75 #define PRES_SPELLCHECK»» » » » » 0x0008L | 71 // richedit styles |
| 76 #define PRES_UNDO» » » » » » » 0x0100L | 72 #define PRES_MULTILINE 0x0001L |
| 77 #define PRES_MULTIPAGES»» » » » » 0x0200L | 73 #define PRES_AUTORETURN 0x0002L |
| 78 #define PRES_TEXTOVERFLOW» » » » » 0x0400L | 74 #define PRES_AUTOSCROLL 0x0004L |
| 79 | 75 #define PRES_SPELLCHECK 0x0008L |
| 80 //border style | 76 #define PRES_UNDO 0x0100L |
| 81 #define PBS_SOLID» » » » » » » 0 | 77 #define PRES_MULTIPAGES 0x0200L |
| 82 #define PBS_DASH» » » » » » » 1 | 78 #define PRES_TEXTOVERFLOW 0x0400L |
| 83 #define PBS_BEVELED» » » » » » » 2 | 79 |
| 84 #define PBS_INSET» » » » » » » 3 | 80 // border style |
| 85 #define PBS_UNDERLINED» » » » » » 4 | 81 #define PBS_SOLID 0 |
| 86 #define PBS_SHADOW» » » » » » » 5 | 82 #define PBS_DASH 1 |
| 87 | 83 #define PBS_BEVELED 2 |
| 88 //notification messages | 84 #define PBS_INSET 3 |
| 89 #define PNM_ADDCHILD» » » » » » 0x00000000L | 85 #define PBS_UNDERLINED 4 |
| 90 #define PNM_REMOVECHILD»» » » » » 0x00000001L | 86 #define PBS_SHADOW 5 |
| 91 #define PNM_SETSCROLLINFO» » » » » 0x00000002L | 87 |
| 92 #define PNM_SETSCROLLPOS» » » » » 0x00000003L | 88 // notification messages |
| 93 #define PNM_SCROLLWINDOW» » » » » 0x00000004L | 89 #define PNM_ADDCHILD 0x00000000L |
| 94 #define PNM_LBUTTONDOWN»» » » » » 0x00000005L | 90 #define PNM_REMOVECHILD 0x00000001L |
| 95 #define PNM_LBUTTONUP» » » » » » 0x00000006L | 91 #define PNM_SETSCROLLINFO 0x00000002L |
| 96 #define PNM_MOUSEMOVE» » » » » » 0x00000007L | 92 #define PNM_SETSCROLLPOS 0x00000003L |
| 97 #define»PNM_NOTERESET» » » » » » 0x00000008L | 93 #define PNM_SCROLLWINDOW 0x00000004L |
| 98 #define PNM_SETCARETINFO» » » » » 0x00000009L | 94 #define PNM_LBUTTONDOWN 0x00000005L |
| 99 #define PNM_SELCHANGED» » » » » » 0x0000000AL | 95 #define PNM_LBUTTONUP 0x00000006L |
| 100 #define»PNM_NOTEEDITCHANGED» » » » » 0x0000000BL | 96 #define PNM_MOUSEMOVE 0x00000007L |
| 101 | 97 #define PNM_NOTERESET 0x00000008L |
| 102 #define PWL_CLASSNAME_EDIT» » » » » "CPWL_Edit" | 98 #define PNM_SETCARETINFO 0x00000009L |
| 103 | 99 #define PNM_SELCHANGED 0x0000000AL |
| 104 struct CPWL_Dash | 100 #define PNM_NOTEEDITCHANGED 0x0000000BL |
| 105 { | 101 |
| 106 » CPWL_Dash(FX_INT32 dash, FX_INT32 gap, FX_INT32 phase) : nDash(dash), nG
ap(gap), nPhase(phase) | 102 #define PWL_CLASSNAME_EDIT "CPWL_Edit" |
| 107 » {} | 103 |
| 108 | 104 struct CPWL_Dash { |
| 109 » FX_INT32» » » nDash; | 105 CPWL_Dash(FX_INT32 dash, FX_INT32 gap, FX_INT32 phase) |
| 110 » FX_INT32» » » nGap; | 106 : nDash(dash), nGap(gap), nPhase(phase) {} |
| 111 » FX_INT32» » » nPhase; | 107 |
| 112 }; | 108 FX_INT32 nDash; |
| 113 | 109 FX_INT32 nGap; |
| 114 struct PWL_CLASS CPWL_Color | 110 FX_INT32 nPhase; |
| 115 { | 111 }; |
| 116 » CPWL_Color(FX_INT32 type = COLORTYPE_TRANSPARENT, FX_FLOAT color1 = 0.0f
, FX_FLOAT color2 = 0.0f, FX_FLOAT color3 = 0.0f, FX_FLOAT color4 = 0.0f) | 112 |
| 117 » » : nColorType(type), fColor1(color1), fColor2(color2), fColor3(co
lor3), fColor4(color4) | 113 struct PWL_CLASS CPWL_Color { |
| 118 » {} | 114 CPWL_Color(FX_INT32 type = COLORTYPE_TRANSPARENT, |
| 119 | 115 FX_FLOAT color1 = 0.0f, |
| 120 » CPWL_Color(FX_INT32 r, FX_INT32 g, FX_INT32 b) : | 116 FX_FLOAT color2 = 0.0f, |
| 121 » » nColorType(COLORTYPE_RGB), fColor1(r/255.0f), fColor2(g/255.0f),
fColor3(b/255.0f), fColor4(0) | 117 FX_FLOAT color3 = 0.0f, |
| 122 » {} | 118 FX_FLOAT color4 = 0.0f) |
| 123 » | 119 : nColorType(type), |
| 124 » void ConvertColorType(FX_INT32 nColorType); | 120 fColor1(color1), |
| 125 | 121 fColor2(color2), |
| 126 » /* | 122 fColor3(color3), |
| 127 » COLORTYPE_TRANSPARENT | 123 fColor4(color4) {} |
| 128 » COLORTYPE_RGB | 124 |
| 129 » COLORTYPE_CMYK | 125 CPWL_Color(FX_INT32 r, FX_INT32 g, FX_INT32 b) |
| 130 » COLORTYPE_GRAY | 126 : nColorType(COLORTYPE_RGB), |
| 131 » */ | 127 fColor1(r / 255.0f), |
| 132 » FX_INT32» » » » » nColorType; | 128 fColor2(g / 255.0f), |
| 133 » FX_FLOAT» » » » » fColor1,fColor2,fColor3,
fColor4; | 129 fColor3(b / 255.0f), |
| 134 }; | 130 fColor4(0) {} |
| 135 | 131 |
| 136 inline FX_BOOL operator == (const CPWL_Color &c1, const CPWL_Color &c2) | 132 void ConvertColorType(FX_INT32 nColorType); |
| 137 { | 133 |
| 138 » return c1.nColorType == c2.nColorType && | 134 /* |
| 139 » » c1.fColor1 - c2.fColor1 < 0.0001 && c1.fColor1 - c2.fColor1 > -0
.0001 && | 135 COLORTYPE_TRANSPARENT |
| 140 » » c1.fColor2 - c2.fColor2 < 0.0001 && c1.fColor2 - c2.fColor2 > -0
.0001 && | 136 COLORTYPE_RGB |
| 141 » » c1.fColor3 - c2.fColor3 < 0.0001 && c1.fColor3 - c2.fColor3 > -0
.0001 && | 137 COLORTYPE_CMYK |
| 142 » » c1.fColor4 - c2.fColor4 < 0.0001 && c1.fColor4 - c2.fColor4 > -0
.0001; | 138 COLORTYPE_GRAY |
| 139 */ |
| 140 FX_INT32 nColorType; |
| 141 FX_FLOAT fColor1, fColor2, fColor3, fColor4; |
| 142 }; |
| 143 |
| 144 inline FX_BOOL operator==(const CPWL_Color& c1, const CPWL_Color& c2) { |
| 145 return c1.nColorType == c2.nColorType && c1.fColor1 - c2.fColor1 < 0.0001 && |
| 146 c1.fColor1 - c2.fColor1 > -0.0001 && |
| 147 c1.fColor2 - c2.fColor2 < 0.0001 && |
| 148 c1.fColor2 - c2.fColor2 > -0.0001 && |
| 149 c1.fColor3 - c2.fColor3 < 0.0001 && |
| 150 c1.fColor3 - c2.fColor3 > -0.0001 && |
| 151 c1.fColor4 - c2.fColor4 < 0.0001 && c1.fColor4 - c2.fColor4 > -0.0001; |
| 143 } | 152 } |
| 144 | 153 |
| 145 inline FX_BOOL operator != (const CPWL_Color &c1, const CPWL_Color &c2) | 154 inline FX_BOOL operator!=(const CPWL_Color& c1, const CPWL_Color& c2) { |
| 146 { | 155 return !operator==(c1, c2); |
| 147 » return !operator == (c1, c2); | |
| 148 } | 156 } |
| 149 | 157 |
| 150 #define PWL_SCROLLBAR_WIDTH 12.0f | 158 #define PWL_SCROLLBAR_WIDTH 12.0f |
| 151 #define PWL_SCROLLBAR_BUTTON_WIDTH 9.0f | 159 #define PWL_SCROLLBAR_BUTTON_WIDTH 9.0f |
| 152 #define PWL_SCROLLBAR_POSBUTTON_MINWIDTH 2.0f | 160 #define PWL_SCROLLBAR_POSBUTTON_MINWIDTH 2.0f |
| 153 #define PWL_SCROLLBAR_TRANSPARANCY 150 | 161 #define PWL_SCROLLBAR_TRANSPARANCY 150 |
| 154 #define PWL_SCROLLBAR_BKCOLOR CPWL_Color(COLORTYPE_RGB
,220.0f/255.0f,220.0f/255.0f,220.0f/255.0f) | 162 #define PWL_SCROLLBAR_BKCOLOR \ |
| 155 #define PWL_DEFAULT_SELTEXTCOLOR CPWL_Color(COLORTYPE_RGB
,1,1,1) | 163 CPWL_Color(COLORTYPE_RGB, 220.0f / 255.0f, 220.0f / 255.0f, 220.0f / 255.0f) |
| 156 #define PWL_DEFAULT_SELBACKCOLOR CPWL_Color(COLORTYPE_RGB
,0,51.0f/255.0f,113.0f/255.0f) | 164 #define PWL_DEFAULT_SELTEXTCOLOR CPWL_Color(COLORTYPE_RGB, 1, 1, 1) |
| 157 #define PWL_DEFAULT_BACKCOLOR PWL_DEFAULT_SELTEXTCOLOR | 165 #define PWL_DEFAULT_SELBACKCOLOR \ |
| 158 #define PWL_DEFAULT_TEXTCOLOR CPWL_Color(COLORTYPE_RGB
,0,0,0) | 166 CPWL_Color(COLORTYPE_RGB, 0, 51.0f / 255.0f, 113.0f / 255.0f) |
| 159 #define PWL_DEFAULT_FONTSIZE 9.0f | 167 #define PWL_DEFAULT_BACKCOLOR PWL_DEFAULT_SELTEXTCOLOR |
| 160 #define PWL_DEFAULT_BLACKCOLOR CPWL_Color(COLORTYPE_GRA
Y,0) | 168 #define PWL_DEFAULT_TEXTCOLOR CPWL_Color(COLORTYPE_RGB, 0, 0, 0) |
| 161 #define PWL_DEFAULT_WHITECOLOR CPWL_Color(COLORTYPE_GRA
Y,1) | 169 #define PWL_DEFAULT_FONTSIZE 9.0f |
| 162 #define PWL_DEFAULT_HEAVYGRAYCOLOR CPWL_Color(COLORTYPE_GRA
Y,0.50) | 170 #define PWL_DEFAULT_BLACKCOLOR CPWL_Color(COLORTYPE_GRAY, 0) |
| 163 #define PWL_DEFAULT_LIGHTGRAYCOLOR CPWL_Color(COLORTYPE_GRA
Y,0.75) | 171 #define PWL_DEFAULT_WHITECOLOR CPWL_Color(COLORTYPE_GRAY, 1) |
| 164 #define PWL_TRIANGLE_HALFLEN 2.0f | 172 #define PWL_DEFAULT_HEAVYGRAYCOLOR CPWL_Color(COLORTYPE_GRAY, 0.50) |
| 165 #define PWL_CBBUTTON_TRIANGLE_HALFLEN 3.0f | 173 #define PWL_DEFAULT_LIGHTGRAYCOLOR CPWL_Color(COLORTYPE_GRAY, 0.75) |
| 166 #define PWL_INVALIDATE_INFLATE 2 | 174 #define PWL_TRIANGLE_HALFLEN 2.0f |
| 167 | 175 #define PWL_CBBUTTON_TRIANGLE_HALFLEN 3.0f |
| 168 class IPWL_SpellCheck | 176 #define PWL_INVALIDATE_INFLATE 2 |
| 169 { | 177 |
| 170 public: | 178 class IPWL_SpellCheck { |
| 171 virtual FX_BOOL CheckWor
d(FX_LPCSTR sWord) = 0; | 179 public: |
| 172 virtual void SuggestW
ords(FX_LPCSTR sWord, CFX_ByteStringArray & sSuggest) = 0; | 180 virtual FX_BOOL CheckWord(FX_LPCSTR sWord) = 0; |
| 173 }; | 181 virtual void SuggestWords(FX_LPCSTR sWord, CFX_ByteStringArray& sSuggest) = 0; |
| 174 | 182 }; |
| 175 class IPWL_Provider | 183 |
| 176 { | 184 class IPWL_Provider { |
| 177 public: | 185 public: |
| 178 //get a matrix which map user space to CWnd client space | 186 // get a matrix which map user space to CWnd client space |
| 179 virtual CPDF_Matrix GetWindo
wMatrix(void* pAttachedData) = 0; | 187 virtual CPDF_Matrix GetWindowMatrix(void* pAttachedData) = 0; |
| 180 | 188 |
| 181 /* | 189 /* |
| 182 0 L"&Undo\tCtrl+Z" | 190 0 L"&Undo\tCtrl+Z" |
| 183 1 L"&Redo\tCtrl+Shift+Z" | 191 1 L"&Redo\tCtrl+Shift+Z" |
| 184 2 L"Cu&t\tCtrl+X" | 192 2 L"Cu&t\tCtrl+X" |
| 185 3 L"&Copy\tCtrl+C" | 193 3 L"&Copy\tCtrl+C" |
| 186 4 L"&Paste\tCtrl+V" | 194 4 L"&Paste\tCtrl+V" |
| 187 5 L"&Delete" | 195 5 L"&Delete" |
| 188 6 L"&Select All\tCtrl+A" | 196 6 L"&Select All\tCtrl+A" |
| 189 */ | 197 */ |
| 190 virtual CFX_WideString LoadPopupMenuStr
ing(FX_INT32 nIndex) = 0; | 198 virtual CFX_WideString LoadPopupMenuString(FX_INT32 nIndex) = 0; |
| 191 }; | 199 }; |
| 192 | 200 |
| 193 class IPWL_FocusHandler | 201 class IPWL_FocusHandler { |
| 194 { | 202 public: |
| 195 public: | 203 virtual void OnSetFocus(CPWL_Wnd* pWnd) = 0; |
| 196 virtual void OnSetFoc
us(CPWL_Wnd* pWnd) = 0; | 204 virtual void OnKillFocus(CPWL_Wnd* pWnd) = 0; |
| 197 virtual void OnKillFo
cus(CPWL_Wnd* pWnd) = 0; | 205 }; |
| 198 }; | 206 |
| 199 | 207 struct PWL_CREATEPARAM { |
| 200 struct PWL_CREATEPARAM | 208 public: |
| 201 { | 209 PWL_CREATEPARAM() |
| 202 public: | 210 : rcRectWnd(0, 0, 0, 0), |
| 203 PWL_CREATEPARAM() : rcRectWnd(0,0,0,0), | 211 pSystemHandler(NULL), |
| 204 pSystemHandler(NULL), | 212 pFontMap(NULL), |
| 205 pFontMap(NULL), | 213 pProvider(NULL), |
| 206 pProvider(NULL), | 214 pFocusHandler(NULL), |
| 207 pFocusHandler(NULL), | 215 dwFlags(0), |
| 208 dwFlags(0), | 216 sBackgroundColor(), |
| 209 sBackgroundColor(), | 217 hAttachedWnd(NULL), |
| 210 hAttachedWnd(NULL), | 218 pSpellCheck(NULL), |
| 211 pSpellCheck(NULL), | 219 nBorderStyle(PBS_SOLID), |
| 212 nBorderStyle(PBS_SOLID), | 220 dwBorderWidth(1), |
| 213 dwBorderWidth(1), | 221 sBorderColor(), |
| 214 sBorderColor(), | 222 sTextColor(), |
| 215 sTextColor(), | 223 sTextStrokeColor(), |
| 216 sTextStrokeColor(), | 224 nTransparency(255), |
| 217 nTransparency(255), | 225 fFontSize(PWL_DEFAULT_FONTSIZE), |
| 218 fFontSize(PWL_DEFAULT_FONTSIZE), | 226 sDash(3, 0, 0), |
| 219 sDash(3,0,0), | 227 pAttachedData(NULL), |
| 220 pAttachedData(NULL), | 228 pParentWnd(NULL), |
| 221 pParentWnd(NULL), | 229 pMsgControl(NULL), |
| 222 pMsgControl(NULL), | 230 eCursorType(FXCT_ARROW), |
| 223 eCursorType(FXCT_ARROW), | 231 mtChild(1, 0, 0, 1, 0, 0) {} |
| 224 mtChild(1,0,0,1,0,0) | 232 |
| 225 { | 233 CPDF_Rect rcRectWnd; // required |
| 226 } | 234 IFX_SystemHandler* pSystemHandler; // required |
| 227 | 235 IFX_Edit_FontMap* pFontMap; // required for text window |
| 228 CPDF_Rect rcRectWnd;
//required | 236 IPWL_Provider* pProvider; // required for self coordinate |
| 229 IFX_SystemHandler* pSystemHandler; //requir
ed | 237 IPWL_FocusHandler* pFocusHandler; // optional |
| 230 IFX_Edit_FontMap* pFontMap;
//required for text window | 238 FX_DWORD dwFlags; // optional |
| 231 IPWL_Provider* pProvider;
//required for self coordinate | 239 CPWL_Color sBackgroundColor; // optional |
| 232 IPWL_FocusHandler* pFocusHandler; //option
al | 240 FX_HWND hAttachedWnd; // required for no-reader framework |
| 233 FX_DWORD dwFlags;
//optional | 241 IPWL_SpellCheck* pSpellCheck; // required for spellchecking |
| 234 CPWL_Color sBackgroundColor;
//optional | 242 FX_INT32 nBorderStyle; // optional |
| 235 FX_HWND hAttachedWnd;
//required for no-reader framework | 243 FX_INT32 dwBorderWidth; // optional |
| 236 IPWL_SpellCheck* pSpellCheck; //requir
ed for spellchecking | 244 CPWL_Color sBorderColor; // optional |
| 237 FX_INT32 nBorderStyle;
//optional | 245 CPWL_Color sTextColor; // optional |
| 238 FX_INT32 dwBorderWidth;
//optional | 246 CPWL_Color sTextStrokeColor; // optional |
| 239 CPWL_Color sBorderColor;
//optional | 247 FX_INT32 nTransparency; // optional |
| 240 CPWL_Color sTextColor;
//optional | 248 FX_FLOAT fFontSize; // optional |
| 241 CPWL_Color sTextStrokeColor;
//optional | 249 CPWL_Dash sDash; // optional |
| 242 FX_INT32 nTransparency;
//optional | 250 void* pAttachedData; // optional |
| 243 FX_FLOAT fFontSize;
//optional | 251 CPWL_Wnd* pParentWnd; // ignore |
| 244 CPWL_Dash sDash;
//optional | 252 CPWL_MsgControl* pMsgControl; // ignore |
| 245 void* pAttachedData;
//optional | 253 FX_INT32 eCursorType; // ignore |
| 246 CPWL_Wnd* pParentWnd;
//ignore | 254 CPDF_Matrix mtChild; // ignore |
| 247 CPWL_MsgControl* pMsgControl; //ignore | 255 }; |
| 248 FX_INT32 eCursorType;
//ignore | 256 |
| 249 CPDF_Matrix mtChild;
//ignore | 257 class CPWL_Timer { |
| 250 }; | 258 public: |
| 251 | 259 CPWL_Timer(CPWL_TimerHandler* pAttached, IFX_SystemHandler* pSystemHandler); |
| 252 class CPWL_Timer | 260 virtual ~CPWL_Timer(); |
| 253 { | 261 |
| 254 public: | 262 FX_INT32 SetPWLTimer(FX_INT32 nElapse); |
| 255 CPWL_Timer(CPWL_TimerHandler* pAttached, IFX_SystemHandler* pSystemHandl
er); | 263 void KillPWLTimer(); |
| 256 virtual ~CPWL_Timer(); | 264 static void TimerProc(FX_INT32 idEvent); |
| 257 | 265 |
| 258 FX_INT32 SetPWLTi
mer(FX_INT32 nElapse); | 266 private: |
| 259 void KillPWLT
imer(); | 267 FX_INT32 m_nTimerID; |
| 260 static void TimerProc(FX_INT
32 idEvent); | 268 CPWL_TimerHandler* m_pAttached; |
| 261 | 269 IFX_SystemHandler* m_pSystemHandler; |
| 262 private: | 270 }; |
| 263 FX_INT32 m_nTimer
ID; | 271 |
| 264 CPWL_TimerHandler* m_pAttached; | 272 class PWL_CLASS CPWL_TimerHandler { |
| 265 IFX_SystemHandler* m_pSystemHandler
; | 273 public: |
| 266 }; | 274 CPWL_TimerHandler(); |
| 267 | 275 virtual ~CPWL_TimerHandler(); |
| 268 class PWL_CLASS CPWL_TimerHandler | 276 |
| 269 { | 277 void BeginTimer(FX_INT32 nElapse); |
| 270 public: | 278 void EndTimer(); |
| 271 CPWL_TimerHandler(); | 279 virtual void TimerProc(); |
| 272 virtual ~CPWL_TimerHandler(); | 280 virtual IFX_SystemHandler* GetSystemHandler() const = 0; |
| 273 | 281 |
| 274 void BeginTim
er(FX_INT32 nElapse); | 282 private: |
| 275 void EndTimer
(); | 283 CPWL_Timer* m_pTimer; |
| 276 virtual void TimerProc(); | 284 }; |
| 277 virtual IFX_SystemHandler* GetSystemHandler() const
= 0; | 285 |
| 278 | 286 class PWL_CLASS CPWL_Wnd : public CPWL_TimerHandler { |
| 279 private: | 287 friend class CPWL_MsgControl; |
| 280 CPWL_Timer* m_pTimer
; | 288 |
| 281 }; | 289 public: |
| 282 | 290 CPWL_Wnd(); |
| 283 class PWL_CLASS CPWL_Wnd : public CPWL_TimerHandler | 291 virtual ~CPWL_Wnd(); |
| 284 { | 292 |
| 285 friend class CPWL_MsgControl; | 293 void Create(const PWL_CREATEPARAM& cp); |
| 286 public: | 294 virtual CFX_ByteString GetClassName() const; |
| 287 CPWL_Wnd(); | 295 void Destroy(); |
| 288 virtual ~CPWL_Wnd(); | 296 void Move(const CPDF_Rect& rcNew, FX_BOOL bReset, FX_BOOL bRefresh); |
| 289 | 297 virtual void InvalidateRect(CPDF_Rect* pRect = NULL); |
| 290 void Create(const PWL
_CREATEPARAM & cp); | 298 |
| 291 virtual CFX_ByteString GetClassName() const; | 299 void GetAppearanceStream(CFX_ByteString& sAppStream); |
| 292 void Destroy(); | 300 void DrawAppearance(CFX_RenderDevice* pDevice, CPDF_Matrix* pUser2Device); |
| 293 void Move(const CPDF_
Rect & rcNew,FX_BOOL bReset,FX_BOOL bRefresh); | 301 |
| 294 virtual void InvalidateRect(CPDF_Rect
* pRect = NULL); | 302 virtual FX_BOOL OnKeyDown(FX_WORD nChar, FX_DWORD nFlag); |
| 295 | 303 virtual FX_BOOL OnKeyUp(FX_WORD nChar, FX_DWORD nFlag); |
| 296 void GetAppearanceStr
eam(CFX_ByteString & sAppStream); | 304 virtual FX_BOOL OnChar(FX_WORD nChar, FX_DWORD nFlag); |
| 297 void DrawAppearance(C
FX_RenderDevice* pDevice, CPDF_Matrix* pUser2Device); | 305 virtual FX_BOOL OnLButtonDblClk(const CPDF_Point& point, FX_DWORD nFlag); |
| 298 | 306 virtual FX_BOOL OnLButtonDown(const CPDF_Point& point, FX_DWORD nFlag); |
| 299 virtual FX_BOOL OnKeyDown(FX_WORD nChar,
FX_DWORD nFlag); | 307 virtual FX_BOOL OnLButtonUp(const CPDF_Point& point, FX_DWORD nFlag); |
| 300 virtual FX_BOOL OnKeyUp(FX_WORD nChar, F
X_DWORD nFlag); | 308 virtual FX_BOOL OnMButtonDblClk(const CPDF_Point& point, FX_DWORD nFlag); |
| 301 virtual FX_BOOL OnChar(FX_WORD nChar, FX
_DWORD nFlag); | 309 virtual FX_BOOL OnMButtonDown(const CPDF_Point& point, FX_DWORD nFlag); |
| 302 virtual FX_BOOL OnLButtonDblClk(const CP
DF_Point & point, FX_DWORD nFlag); | 310 virtual FX_BOOL OnMButtonUp(const CPDF_Point& point, FX_DWORD nFlag); |
| 303 virtual FX_BOOL OnLButtonDown(const CPDF
_Point & point, FX_DWORD nFlag); | 311 virtual FX_BOOL OnRButtonDblClk(const CPDF_Point& point, FX_DWORD nFlag); |
| 304 virtual FX_BOOL OnLButtonUp(const CPDF_P
oint & point, FX_DWORD nFlag); | 312 virtual FX_BOOL OnRButtonDown(const CPDF_Point& point, FX_DWORD nFlag); |
| 305 virtual FX_BOOL OnMButtonDblClk(const CP
DF_Point & point, FX_DWORD nFlag); | 313 virtual FX_BOOL OnRButtonUp(const CPDF_Point& point, FX_DWORD nFlag); |
| 306 virtual FX_BOOL OnMButtonDown(const CPDF
_Point & point, FX_DWORD nFlag); | 314 virtual FX_BOOL OnMouseMove(const CPDF_Point& point, FX_DWORD nFlag); |
| 307 virtual FX_BOOL OnMButtonUp(const CPDF_P
oint & point, FX_DWORD nFlag); | 315 virtual FX_BOOL OnMouseWheel(short zDelta, |
| 308 virtual FX_BOOL OnRButtonDblClk(const CP
DF_Point & point, FX_DWORD nFlag); | 316 const CPDF_Point& point, |
| 309 virtual FX_BOOL OnRButtonDown(const CPDF
_Point & point, FX_DWORD nFlag); | 317 FX_DWORD nFlag); |
| 310 virtual FX_BOOL OnRButtonUp(const CPDF_P
oint & point, FX_DWORD nFlag); | 318 |
| 311 virtual FX_BOOL OnMouseMove(const CPDF_P
oint & point, FX_DWORD nFlag); | 319 virtual void SetFocus(); |
| 312 virtual FX_BOOL OnMouseWheel(short zDelt
a, const CPDF_Point & point, FX_DWORD nFlag); | 320 virtual void KillFocus(); |
| 313 | 321 void SetCapture(); |
| 314 virtual void SetFocus(); | 322 void ReleaseCapture(); |
| 315 virtual void KillFocus(); | 323 |
| 316 void SetCapture(); | 324 virtual void OnNotify(CPWL_Wnd* pWnd, |
| 317 void ReleaseCapture()
; | 325 FX_DWORD msg, |
| 318 | 326 FX_INTPTR wParam = 0, |
| 319 virtual void OnNotify(CPWL_Wnd* pWnd,
FX_DWORD msg, FX_INTPTR wParam = 0, FX_INTPTR lParam = 0); | 327 FX_INTPTR lParam = 0); |
| 320 virtual void SetTextColor(const CPWL_
Color & color); | 328 virtual void SetTextColor(const CPWL_Color& color); |
| 321 virtual void SetTextStrokeColor(const
CPWL_Color & color); | 329 virtual void SetTextStrokeColor(const CPWL_Color& color); |
| 322 virtual void SetVisible(FX_BOOL bVisi
ble); | 330 virtual void SetVisible(FX_BOOL bVisible); |
| 323 | 331 |
| 324 virtual CPDF_Rect GetFocusRect() const; | 332 virtual CPDF_Rect GetFocusRect() const; |
| 325 virtual CPWL_Color GetBackgroundColor() con
st; | 333 virtual CPWL_Color GetBackgroundColor() const; |
| 326 virtual CPWL_Color GetBorderColor() const; | 334 virtual CPWL_Color GetBorderColor() const; |
| 327 virtual CPWL_Color GetTextColor() const; | 335 virtual CPWL_Color GetTextColor() const; |
| 328 virtual CPWL_Color GetTextStrokeColor() con
st; | 336 virtual CPWL_Color GetTextStrokeColor() const; |
| 329 virtual FX_FLOAT GetFontSize() const; | 337 virtual FX_FLOAT GetFontSize() const; |
| 330 virtual FX_INT32 GetInnerBorderWidth() co
nst; | 338 virtual FX_INT32 GetInnerBorderWidth() const; |
| 331 virtual CPWL_Color GetBorderLeftTopColor(FX
_INT32 nBorderStyle) const; | 339 virtual CPWL_Color GetBorderLeftTopColor(FX_INT32 nBorderStyle) const; |
| 332 virtual CPWL_Color GetBorderRightBottomColo
r(FX_INT32 nBorderStyle) const; | 340 virtual CPWL_Color GetBorderRightBottomColor(FX_INT32 nBorderStyle) const; |
| 333 | 341 |
| 334 virtual FX_BOOL IsModified() const {retu
rn FALSE;} | 342 virtual FX_BOOL IsModified() const { return FALSE; } |
| 335 | 343 |
| 336 virtual void SetFontSize(FX_FLOAT fFo
ntSize); | 344 virtual void SetFontSize(FX_FLOAT fFontSize); |
| 337 | 345 |
| 338 void SetBackgroundCol
or(const CPWL_Color & color); | 346 void SetBackgroundColor(const CPWL_Color& color); |
| 339 void SetBorderColor(c
onst CPWL_Color & color); | 347 void SetBorderColor(const CPWL_Color& color); |
| 340 void SetBorderWidth(F
X_INT32 nBorderWidth); | 348 void SetBorderWidth(FX_INT32 nBorderWidth); |
| 341 void SetClipRect(cons
t CPDF_Rect & rect); | 349 void SetClipRect(const CPDF_Rect& rect); |
| 342 void SetBorderStyle(F
X_INT32 eBorderStyle); | 350 void SetBorderStyle(FX_INT32 eBorderStyle); |
| 343 void SetBorderDash(co
nst CPWL_Dash & sDash); | 351 void SetBorderDash(const CPWL_Dash& sDash); |
| 344 | 352 |
| 345 CPDF_Rect GetOriginWindowR
ect() const; | 353 CPDF_Rect GetOriginWindowRect() const; |
| 346 virtual CPDF_Rect GetWindowRect() const; | 354 virtual CPDF_Rect GetWindowRect() const; |
| 347 virtual CPDF_Rect GetClientRect() const; | 355 virtual CPDF_Rect GetClientRect() const; |
| 348 CPDF_Point GetCenterPoint()
const; | 356 CPDF_Point GetCenterPoint() const; |
| 349 CPDF_Rect GetClientCenterS
quare() const; | 357 CPDF_Rect GetClientCenterSquare() const; |
| 350 CPDF_Rect GetWindowCenterS
quare() const; | 358 CPDF_Rect GetWindowCenterSquare() const; |
| 351 FX_INT32 GetBorderWidth()
const; | 359 FX_INT32 GetBorderWidth() const; |
| 352 FX_BOOL IsVisible() cons
t {return m_bVisible;} | 360 FX_BOOL IsVisible() const { return m_bVisible; } |
| 353 FX_BOOL HasFlag(FX_DWORD
dwFlags) const; | 361 FX_BOOL HasFlag(FX_DWORD dwFlags) const; |
| 354 void AddFlag(FX_DWORD
dwFlags); | 362 void AddFlag(FX_DWORD dwFlags); |
| 355 void RemoveFlag(FX_DW
ORD dwFlags); | 363 void RemoveFlag(FX_DWORD dwFlags); |
| 356 CPDF_Rect GetClipRect() co
nst; | 364 CPDF_Rect GetClipRect() const; |
| 357 CPWL_Wnd* GetParentWindow(
) const; | 365 CPWL_Wnd* GetParentWindow() const; |
| 358 FX_INT32 GetBorderStyle()
const; | 366 FX_INT32 GetBorderStyle() const; |
| 359 CPWL_Dash GetBorderDash()
const; | 367 CPWL_Dash GetBorderDash() const; |
| 360 void* GetAttachedData(
) const; | 368 void* GetAttachedData() const; |
| 361 | 369 |
| 362 FX_BOOL WndHitTest(const
CPDF_Point & point) const; | 370 FX_BOOL WndHitTest(const CPDF_Point& point) const; |
| 363 FX_BOOL ClientHitTest(co
nst CPDF_Point & point) const; | 371 FX_BOOL ClientHitTest(const CPDF_Point& point) const; |
| 364 FX_BOOL IsCaptureMouse()
const; | 372 FX_BOOL IsCaptureMouse() const; |
| 365 | 373 |
| 366 const CPWL_Wnd* GetFocused() const; | 374 const CPWL_Wnd* GetFocused() const; |
| 367 FX_BOOL IsFocused() cons
t; | 375 FX_BOOL IsFocused() const; |
| 368 FX_BOOL IsReadOnly() con
st; | 376 FX_BOOL IsReadOnly() const; |
| 369 CPWL_ScrollBar* GetVScrollBar() const; | 377 CPWL_ScrollBar* GetVScrollBar() const; |
| 370 | 378 |
| 371 IFX_Edit_FontMap* GetFontMap() const; | 379 IFX_Edit_FontMap* GetFontMap() const; |
| 372 IPWL_Provider* GetProvider() const; | 380 IPWL_Provider* GetProvider() const; |
| 373 virtual IFX_SystemHandler* GetSystemHandler() const; | 381 virtual IFX_SystemHandler* GetSystemHandler() const; |
| 374 IPWL_FocusHandler* GetFocusHandler() const; | 382 IPWL_FocusHandler* GetFocusHandler() const; |
| 375 | 383 |
| 376 FX_INT32 GetTransparency(
); | 384 FX_INT32 GetTransparency(); |
| 377 void SetTransparency(
FX_INT32 nTransparency); | 385 void SetTransparency(FX_INT32 nTransparency); |
| 378 | 386 |
| 379 CPDF_Matrix GetChildToRoot()
const; | 387 CPDF_Matrix GetChildToRoot() const; |
| 380 CPDF_Matrix GetChildMatrix()
const; | 388 CPDF_Matrix GetChildMatrix() const; |
| 381 void SetChildMatrix(c
onst CPDF_Matrix& mt); | 389 void SetChildMatrix(const CPDF_Matrix& mt); |
| 382 CPDF_Matrix GetWindowMatrix(
) const; | 390 CPDF_Matrix GetWindowMatrix() const; |
| 383 | 391 |
| 384 virtual CPDF_Point ChildToParent(const CPDF
_Point& point) const; | 392 virtual CPDF_Point ChildToParent(const CPDF_Point& point) const; |
| 385 virtual CPDF_Rect ChildToParent(const CPDF
_Rect& rect) const; | 393 virtual CPDF_Rect ChildToParent(const CPDF_Rect& rect) const; |
| 386 virtual CPDF_Point ParentToChild(const CPDF
_Point& point) const; | 394 virtual CPDF_Point ParentToChild(const CPDF_Point& point) const; |
| 387 virtual CPDF_Rect ParentToChild(const CPDF
_Rect& rect) const; | 395 virtual CPDF_Rect ParentToChild(const CPDF_Rect& rect) const; |
| 388 | 396 |
| 389 //those methods only implemented by listctrl item | 397 // those methods only implemented by listctrl item |
| 390 virtual FX_FLOAT GetItemHeight(FX_FLOAT f
LimitWidth) {return 0;} | 398 virtual FX_FLOAT GetItemHeight(FX_FLOAT fLimitWidth) { return 0; } |
| 391 virtual FX_FLOAT GetItemLeftMargin() {ret
urn 0;} | 399 virtual FX_FLOAT GetItemLeftMargin() { return 0; } |
| 392 virtual FX_FLOAT GetItemRightMargin() {re
turn 0;} | 400 virtual FX_FLOAT GetItemRightMargin() { return 0; } |
| 393 | 401 |
| 394 void EnableWindow(FX_
BOOL bEnable); | 402 void EnableWindow(FX_BOOL bEnable); |
| 395 FX_BOOL IsEnabled(); | 403 FX_BOOL IsEnabled(); |
| 396 virtual void SetCursor(); | 404 virtual void SetCursor(); |
| 397 | 405 |
| 398 protected: | 406 protected: |
| 399 virtual void CreateChildWnd(const PWL
_CREATEPARAM & cp); | 407 virtual void CreateChildWnd(const PWL_CREATEPARAM& cp); |
| 400 virtual void RePosChildWnd(); | 408 virtual void RePosChildWnd(); |
| 401 void GetAppearanceStr
eam(CFX_ByteTextBuf & sAppStream); | 409 void GetAppearanceStream(CFX_ByteTextBuf& sAppStream); |
| 402 virtual void GetThisAppearanceStream(
CFX_ByteTextBuf & sAppStream); | 410 virtual void GetThisAppearanceStream(CFX_ByteTextBuf& sAppStream); |
| 403 virtual void GetChildAppearanceStream
(CFX_ByteTextBuf & sAppStream); | 411 virtual void GetChildAppearanceStream(CFX_ByteTextBuf& sAppStream); |
| 404 | 412 |
| 405 virtual void DrawThisAppearance(CFX_R
enderDevice* pDevice, CPDF_Matrix* pUser2Device); | 413 virtual void DrawThisAppearance(CFX_RenderDevice* pDevice, |
| 406 virtual void DrawChildAppearance(CFX_
RenderDevice* pDevice, CPDF_Matrix* pUser2Device); | 414 CPDF_Matrix* pUser2Device); |
| 407 | 415 virtual void DrawChildAppearance(CFX_RenderDevice* pDevice, |
| 408 virtual void OnCreate(PWL_CREATEPARAM
& cp); | 416 CPDF_Matrix* pUser2Device); |
| 409 virtual void OnCreated(); | 417 |
| 410 virtual void OnDestroy(); | 418 virtual void OnCreate(PWL_CREATEPARAM& cp); |
| 411 | 419 virtual void OnCreated(); |
| 412 virtual void OnSetFocus(); | 420 virtual void OnDestroy(); |
| 413 virtual void OnKillFocus(); | 421 |
| 414 | 422 virtual void OnSetFocus(); |
| 415 virtual void OnEnabled(); | 423 virtual void OnKillFocus(); |
| 416 virtual void OnDisabled(); | 424 |
| 417 | 425 virtual void OnEnabled(); |
| 418 void SetNotifyFlag(FX
_BOOL bNotifying = TRUE){m_bNotifying = bNotifying;}; | 426 virtual void OnDisabled(); |
| 419 | 427 |
| 420 FX_BOOL IsValid() const; | 428 void SetNotifyFlag(FX_BOOL bNotifying = TRUE) { m_bNotifying = bNotifying; }; |
| 421 PWL_CREATEPARAM GetCreationParam() const
; | 429 |
| 422 FX_BOOL IsNotifying() co
nst {return m_bNotifying;} | 430 FX_BOOL IsValid() const; |
| 423 | 431 PWL_CREATEPARAM GetCreationParam() const; |
| 424 void InvalidateRectMo
ve(const CPDF_Rect & rcOld, const CPDF_Rect & rcNew); | 432 FX_BOOL IsNotifying() const { return m_bNotifying; } |
| 425 | 433 |
| 426 void PWLtoWnd(const C
PDF_Point & point, FX_INT32& x, FX_INT32& y) const; | 434 void InvalidateRectMove(const CPDF_Rect& rcOld, const CPDF_Rect& rcNew); |
| 427 FX_RECT PWLtoWnd(const C
PDF_Rect & rect) const; | 435 |
| 428 FX_HWND GetAttachedHWnd(
) const; | 436 void PWLtoWnd(const CPDF_Point& point, FX_INT32& x, FX_INT32& y) const; |
| 429 | 437 FX_RECT PWLtoWnd(const CPDF_Rect& rect) const; |
| 430 FX_BOOL IsWndCaptureMous
e(const CPWL_Wnd * pWnd) const; | 438 FX_HWND GetAttachedHWnd() const; |
| 431 FX_BOOL IsWndCaptureKeyb
oard(const CPWL_Wnd * pWnd) const; | 439 |
| 432 const CPWL_Wnd* GetRootWnd() const; | 440 FX_BOOL IsWndCaptureMouse(const CPWL_Wnd* pWnd) const; |
| 433 | 441 FX_BOOL IsWndCaptureKeyboard(const CPWL_Wnd* pWnd) const; |
| 434 FX_BOOL IsCTRLpressed(FX
_DWORD nFlag) const; | 442 const CPWL_Wnd* GetRootWnd() const; |
| 435 FX_BOOL IsSHIFTpressed(F
X_DWORD nFlag) const; | 443 |
| 436 FX_BOOL IsALTpressed(FX_
DWORD nFlag) const; | 444 FX_BOOL IsCTRLpressed(FX_DWORD nFlag) const; |
| 437 FX_BOOL IsINSERTpressed(
FX_DWORD nFlag) const; | 445 FX_BOOL IsSHIFTpressed(FX_DWORD nFlag) const; |
| 438 | 446 FX_BOOL IsALTpressed(FX_DWORD nFlag) const; |
| 439 private: | 447 FX_BOOL IsINSERTpressed(FX_DWORD nFlag) const; |
| 440 void AddChild(CPWL_Wn
d * pWnd); | 448 |
| 441 void RemoveChild(CPWL
_Wnd * pWnd); | 449 private: |
| 442 | 450 void AddChild(CPWL_Wnd* pWnd); |
| 443 void CreateScrollBar(
const PWL_CREATEPARAM & cp); | 451 void RemoveChild(CPWL_Wnd* pWnd); |
| 444 void CreateVScrollBar
(const PWL_CREATEPARAM & cp); | 452 |
| 445 | 453 void CreateScrollBar(const PWL_CREATEPARAM& cp); |
| 446 void AjustStyle(); | 454 void CreateVScrollBar(const PWL_CREATEPARAM& cp); |
| 447 void CreateMsgControl
(); | 455 |
| 448 void DestroyMsgContro
l(); | 456 void AjustStyle(); |
| 449 | 457 void CreateMsgControl(); |
| 450 CPWL_MsgControl* GetMsgControl() const; | 458 void DestroyMsgControl(); |
| 451 | 459 |
| 452 protected: | 460 CPWL_MsgControl* GetMsgControl() const; |
| 453 CFX_ArrayTemplate<CPWL_Wnd*> m_aChildren; | 461 |
| 454 | 462 protected: |
| 455 private: | 463 CFX_ArrayTemplate<CPWL_Wnd*> m_aChildren; |
| 456 PWL_CREATEPARAM m_sPrivateParam; | 464 |
| 457 | 465 private: |
| 458 CPWL_ScrollBar* m_pVScrollBar; | 466 PWL_CREATEPARAM m_sPrivateParam; |
| 459 | 467 |
| 460 CPDF_Rect m_rcWindow; | 468 CPWL_ScrollBar* m_pVScrollBar; |
| 461 CPDF_Rect m_rcClip; | 469 |
| 462 | 470 CPDF_Rect m_rcWindow; |
| 463 FX_BOOL m_bCreated;
| 471 CPDF_Rect m_rcClip; |
| 464 FX_BOOL m_bVisible; | 472 |
| 465 FX_BOOL m_bNotifying; | 473 FX_BOOL m_bCreated; |
| 466 FX_BOOL m_bEnabled; | 474 FX_BOOL m_bVisible; |
| 475 FX_BOOL m_bNotifying; |
| 476 FX_BOOL m_bEnabled; |
| 467 }; | 477 }; |
| 468 | 478 |
| 469 // #ifndef VK_END | 479 // #ifndef VK_END |
| 470 // | 480 // |
| 471 // #define VK_END 0x23 | 481 // #define VK_END 0x23 |
| 472 // #define VK_HOME 0x24 | 482 // #define VK_HOME 0x24 |
| 473 // #define VK_LEFT 0x25 | 483 // #define VK_LEFT 0x25 |
| 474 // #define VK_UP 0x26 | 484 // #define VK_UP 0x26 |
| 475 // #define VK_RIGHT 0x27 | 485 // #define VK_RIGHT 0x27 |
| 476 // #define VK_DOWN 0x28 | 486 // #define VK_DOWN 0x28 |
| 477 // #define VK_INSERT 0x2D | 487 // #define VK_INSERT 0x2D |
| 478 // #define VK_DELETE 0x2E | 488 // #define VK_DELETE 0x2E |
| 479 // | 489 // |
| 480 // #define VK_BACK 0x08 | 490 // #define VK_BACK 0x08 |
| 481 // #define VK_TAB 0x09 | 491 // #define VK_TAB 0x09 |
| 482 // | 492 // |
| 483 // #define VK_CLEAR 0x0C | 493 // #define VK_CLEAR 0x0C |
| 484 // #define VK_RETURN 0x0D | 494 // #define VK_RETURN 0x0D |
| 485 // #define VK_ESCAPE 0x1B | 495 // #define VK_ESCAPE 0x1B |
| 486 // #define VK_SPACE 0x20 | 496 // #define VK_SPACE 0x20 |
| 487 // #endif | 497 // #endif |
| 488 // | 498 // |
| 489 // #define VK_NONE 0 | 499 // #define VK_NONE 0 |
| 490 | 500 |
| 491 #endif // !defined(AFX_PWL_WND_H__D32812AD_A875_4E08_9D3C_0A57020987C6__INCLUDED
_) | 501 #endif // !defined(AFX_PWL_WND_H__D32812AD_A875_4E08_9D3C_0A57020987C6__INCLUDE
D_) |
| 492 | |
| 493 | |
| OLD | NEW |