Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(899)

Side by Side Diff: xfa/fwl/basewidget/fwl_checkboximp.cpp

Issue 1952693003: Convert FWL_ERR into an enum class. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « xfa/fwl/basewidget/fwl_checkboximp.h ('k') | xfa/fwl/basewidget/fwl_comboboximp.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "xfa/fwl/basewidget/fwl_checkboximp.h" 7 #include "xfa/fwl/basewidget/fwl_checkboximp.h"
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 19 matching lines...) Expand all
30 IFWL_CheckBox* pCheckBox = new IFWL_CheckBox; 30 IFWL_CheckBox* pCheckBox = new IFWL_CheckBox;
31 CFWL_CheckBoxImp* pCheckBoxImpl = new CFWL_CheckBoxImp(properties, pOuter); 31 CFWL_CheckBoxImp* pCheckBoxImpl = new CFWL_CheckBoxImp(properties, pOuter);
32 pCheckBox->SetImpl(pCheckBoxImpl); 32 pCheckBox->SetImpl(pCheckBoxImpl);
33 pCheckBoxImpl->SetInterface(pCheckBox); 33 pCheckBoxImpl->SetInterface(pCheckBox);
34 return pCheckBox; 34 return pCheckBox;
35 } 35 }
36 IFWL_CheckBox::IFWL_CheckBox() {} 36 IFWL_CheckBox::IFWL_CheckBox() {}
37 int32_t IFWL_CheckBox::GetCheckState() { 37 int32_t IFWL_CheckBox::GetCheckState() {
38 return static_cast<CFWL_CheckBoxImp*>(GetImpl())->GetCheckState(); 38 return static_cast<CFWL_CheckBoxImp*>(GetImpl())->GetCheckState();
39 } 39 }
40 FWL_ERR IFWL_CheckBox::SetCheckState(int32_t iCheck) { 40 FWL_Error IFWL_CheckBox::SetCheckState(int32_t iCheck) {
41 return static_cast<CFWL_CheckBoxImp*>(GetImpl())->SetCheckState(iCheck); 41 return static_cast<CFWL_CheckBoxImp*>(GetImpl())->SetCheckState(iCheck);
42 } 42 }
43 43
44 CFWL_CheckBoxImp::CFWL_CheckBoxImp(const CFWL_WidgetImpProperties& properties, 44 CFWL_CheckBoxImp::CFWL_CheckBoxImp(const CFWL_WidgetImpProperties& properties,
45 IFWL_Widget* pOuter) 45 IFWL_Widget* pOuter)
46 : CFWL_WidgetImp(properties, pOuter), 46 : CFWL_WidgetImp(properties, pOuter),
47 m_dwTTOStyles(FDE_TTOSTYLE_SingleLine), 47 m_dwTTOStyles(FDE_TTOSTYLE_SingleLine),
48 m_iTTOAlign(FDE_TTOALIGNMENT_Center), 48 m_iTTOAlign(FDE_TTOALIGNMENT_Center),
49 m_bBtnDown(FALSE) { 49 m_bBtnDown(FALSE) {
50 m_rtClient.Reset(); 50 m_rtClient.Reset();
51 m_rtBox.Reset(); 51 m_rtBox.Reset();
52 m_rtCaption.Reset(); 52 m_rtCaption.Reset();
53 m_rtFocus.Reset(); 53 m_rtFocus.Reset();
54 } 54 }
55 CFWL_CheckBoxImp::~CFWL_CheckBoxImp() {} 55 CFWL_CheckBoxImp::~CFWL_CheckBoxImp() {}
56 FWL_ERR CFWL_CheckBoxImp::GetClassName(CFX_WideString& wsClass) const { 56 FWL_Error CFWL_CheckBoxImp::GetClassName(CFX_WideString& wsClass) const {
57 wsClass = FWL_CLASS_CheckBox; 57 wsClass = FWL_CLASS_CheckBox;
58 return FWL_ERR_Succeeded; 58 return FWL_Error::Succeeded;
59 } 59 }
60 uint32_t CFWL_CheckBoxImp::GetClassID() const { 60 uint32_t CFWL_CheckBoxImp::GetClassID() const {
61 return FWL_CLASSHASH_CheckBox; 61 return FWL_CLASSHASH_CheckBox;
62 } 62 }
63 FWL_ERR CFWL_CheckBoxImp::Initialize() { 63 FWL_Error CFWL_CheckBoxImp::Initialize() {
64 if (CFWL_WidgetImp::Initialize() != FWL_ERR_Succeeded) 64 if (CFWL_WidgetImp::Initialize() != FWL_Error::Succeeded)
65 return FWL_ERR_Indefinite; 65 return FWL_Error::Indefinite;
66 m_pDelegate = new CFWL_CheckBoxImpDelegate(this); 66 m_pDelegate = new CFWL_CheckBoxImpDelegate(this);
67 return FWL_ERR_Succeeded; 67 return FWL_Error::Succeeded;
68 } 68 }
69 FWL_ERR CFWL_CheckBoxImp::Finalize() { 69 FWL_Error CFWL_CheckBoxImp::Finalize() {
70 delete m_pDelegate; 70 delete m_pDelegate;
71 m_pDelegate = nullptr; 71 m_pDelegate = nullptr;
72 return CFWL_WidgetImp::Finalize(); 72 return CFWL_WidgetImp::Finalize();
73 } 73 }
74 FWL_ERR CFWL_CheckBoxImp::GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize) { 74 FWL_Error CFWL_CheckBoxImp::GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize) {
75 if (bAutoSize) { 75 if (bAutoSize) {
76 rect.Set(0, 0, 0, 0); 76 rect.Set(0, 0, 0, 0);
77 if (!m_pProperties->m_pThemeProvider) 77 if (!m_pProperties->m_pThemeProvider)
78 m_pProperties->m_pThemeProvider = GetAvailableTheme(); 78 m_pProperties->m_pThemeProvider = GetAvailableTheme();
79 if (!m_pProperties->m_pThemeProvider) 79 if (!m_pProperties->m_pThemeProvider)
80 return FWL_ERR_Indefinite; 80 return FWL_Error::Indefinite;
81 if (!m_pProperties->m_pDataProvider) 81 if (!m_pProperties->m_pDataProvider)
82 return FWL_ERR_Indefinite; 82 return FWL_Error::Indefinite;
83 CFX_WideString wsCaption; 83 CFX_WideString wsCaption;
84 m_pProperties->m_pDataProvider->GetCaption(m_pInterface, wsCaption); 84 m_pProperties->m_pDataProvider->GetCaption(m_pInterface, wsCaption);
85 if (wsCaption.GetLength() > 0) { 85 if (wsCaption.GetLength() > 0) {
86 CFX_SizeF sz = CalcTextSize( 86 CFX_SizeF sz = CalcTextSize(
87 wsCaption, m_pProperties->m_pThemeProvider, 87 wsCaption, m_pProperties->m_pThemeProvider,
88 m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_MultiLine); 88 m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_MultiLine);
89 rect.Set(0, 0, sz.x, sz.y); 89 rect.Set(0, 0, sz.x, sz.y);
90 } 90 }
91 rect.Inflate(kCaptionMargin, kCaptionMargin); 91 rect.Inflate(kCaptionMargin, kCaptionMargin);
92 IFWL_CheckBoxDP* pData = 92 IFWL_CheckBoxDP* pData =
93 static_cast<IFWL_CheckBoxDP*>(m_pProperties->m_pDataProvider); 93 static_cast<IFWL_CheckBoxDP*>(m_pProperties->m_pDataProvider);
94 FX_FLOAT fCheckBox = pData->GetBoxSize(m_pInterface); 94 FX_FLOAT fCheckBox = pData->GetBoxSize(m_pInterface);
95 rect.width += fCheckBox; 95 rect.width += fCheckBox;
96 if (rect.height < fCheckBox) { 96 if (rect.height < fCheckBox) {
97 rect.height = fCheckBox; 97 rect.height = fCheckBox;
98 } 98 }
99 CFWL_WidgetImp::GetWidgetRect(rect, TRUE); 99 CFWL_WidgetImp::GetWidgetRect(rect, TRUE);
100 } else { 100 } else {
101 rect = m_pProperties->m_rtWidget; 101 rect = m_pProperties->m_rtWidget;
102 } 102 }
103 return FWL_ERR_Succeeded; 103 return FWL_Error::Succeeded;
104 } 104 }
105 FWL_ERR CFWL_CheckBoxImp::Update() { 105 FWL_Error CFWL_CheckBoxImp::Update() {
106 if (IsLocked()) { 106 if (IsLocked()) {
107 return FWL_ERR_Indefinite; 107 return FWL_Error::Indefinite;
108 } 108 }
109 if (!m_pProperties->m_pThemeProvider) { 109 if (!m_pProperties->m_pThemeProvider) {
110 m_pProperties->m_pThemeProvider = GetAvailableTheme(); 110 m_pProperties->m_pThemeProvider = GetAvailableTheme();
111 } 111 }
112 UpdateTextOutStyles(); 112 UpdateTextOutStyles();
113 Layout(); 113 Layout();
114 return FWL_ERR_Succeeded; 114 return FWL_Error::Succeeded;
115 } 115 }
116 FWL_ERR CFWL_CheckBoxImp::DrawWidget(CFX_Graphics* pGraphics, 116 FWL_Error CFWL_CheckBoxImp::DrawWidget(CFX_Graphics* pGraphics,
117 const CFX_Matrix* pMatrix) { 117 const CFX_Matrix* pMatrix) {
118 if (!pGraphics) 118 if (!pGraphics)
119 return FWL_ERR_Indefinite; 119 return FWL_Error::Indefinite;
120 if (!m_pProperties->m_pThemeProvider) 120 if (!m_pProperties->m_pThemeProvider)
121 return FWL_ERR_Indefinite; 121 return FWL_Error::Indefinite;
122 IFWL_ThemeProvider* pTheme = m_pProperties->m_pThemeProvider; 122 IFWL_ThemeProvider* pTheme = m_pProperties->m_pThemeProvider;
123 if (HasBorder()) { 123 if (HasBorder()) {
124 DrawBorder(pGraphics, CFWL_Part::Border, m_pProperties->m_pThemeProvider, 124 DrawBorder(pGraphics, CFWL_Part::Border, m_pProperties->m_pThemeProvider,
125 pMatrix); 125 pMatrix);
126 } 126 }
127 if (HasEdge()) { 127 if (HasEdge()) {
128 DrawEdge(pGraphics, CFWL_Part::Edge, pTheme, pMatrix); 128 DrawEdge(pGraphics, CFWL_Part::Edge, pTheme, pMatrix);
129 } 129 }
130 int32_t dwStates = GetPartStates(); 130 int32_t dwStates = GetPartStates();
131 { 131 {
132 CFWL_ThemeBackground param; 132 CFWL_ThemeBackground param;
133 param.m_pWidget = m_pInterface; 133 param.m_pWidget = m_pInterface;
134 param.m_iPart = CFWL_Part::Background; 134 param.m_iPart = CFWL_Part::Background;
135 param.m_dwStates = dwStates; 135 param.m_dwStates = dwStates;
136 param.m_pGraphics = pGraphics; 136 param.m_pGraphics = pGraphics;
137 if (pMatrix) { 137 if (pMatrix) {
138 param.m_matrix.Concat(*pMatrix); 138 param.m_matrix.Concat(*pMatrix);
139 } 139 }
140 param.m_rtPart = m_rtClient; 140 param.m_rtPart = m_rtClient;
141 if (m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) { 141 if (m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) {
142 param.m_pData = &m_rtFocus; 142 param.m_pData = &m_rtFocus;
143 } 143 }
144 pTheme->DrawBackground(&param); 144 pTheme->DrawBackground(&param);
145 param.m_iPart = CFWL_Part::CheckBox; 145 param.m_iPart = CFWL_Part::CheckBox;
146 param.m_rtPart = m_rtBox; 146 param.m_rtPart = m_rtBox;
147 pTheme->DrawBackground(&param); 147 pTheme->DrawBackground(&param);
148 } 148 }
149 if (!m_pProperties->m_pDataProvider) 149 if (!m_pProperties->m_pDataProvider)
150 return FWL_ERR_Indefinite; 150 return FWL_Error::Indefinite;
151 { 151 {
152 CFX_WideString wsCaption; 152 CFX_WideString wsCaption;
153 m_pProperties->m_pDataProvider->GetCaption(m_pInterface, wsCaption); 153 m_pProperties->m_pDataProvider->GetCaption(m_pInterface, wsCaption);
154 int32_t iLen = wsCaption.GetLength(); 154 int32_t iLen = wsCaption.GetLength();
155 if (iLen <= 0) 155 if (iLen <= 0)
156 return FWL_ERR_Indefinite; 156 return FWL_Error::Indefinite;
157 CFWL_ThemeText textParam; 157 CFWL_ThemeText textParam;
158 textParam.m_pWidget = m_pInterface; 158 textParam.m_pWidget = m_pInterface;
159 textParam.m_iPart = CFWL_Part::Caption; 159 textParam.m_iPart = CFWL_Part::Caption;
160 textParam.m_dwStates = dwStates; 160 textParam.m_dwStates = dwStates;
161 textParam.m_pGraphics = pGraphics; 161 textParam.m_pGraphics = pGraphics;
162 if (pMatrix) { 162 if (pMatrix) {
163 textParam.m_matrix.Concat(*pMatrix); 163 textParam.m_matrix.Concat(*pMatrix);
164 } 164 }
165 textParam.m_rtPart = m_rtCaption; 165 textParam.m_rtPart = m_rtCaption;
166 textParam.m_wsText = wsCaption; 166 textParam.m_wsText = wsCaption;
167 textParam.m_dwTTOStyles = m_dwTTOStyles; 167 textParam.m_dwTTOStyles = m_dwTTOStyles;
168 textParam.m_iTTOAlign = m_iTTOAlign; 168 textParam.m_iTTOAlign = m_iTTOAlign;
169 pTheme->DrawText(&textParam); 169 pTheme->DrawText(&textParam);
170 } 170 }
171 return FWL_ERR_Succeeded; 171 return FWL_Error::Succeeded;
172 } 172 }
173 int32_t CFWL_CheckBoxImp::GetCheckState() { 173 int32_t CFWL_CheckBoxImp::GetCheckState() {
174 if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_3State) && 174 if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_3State) &&
175 ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) == 175 ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) ==
176 FWL_STATE_CKB_Neutral)) { 176 FWL_STATE_CKB_Neutral)) {
177 return 2; 177 return 2;
178 } 178 }
179 if ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) == 179 if ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) ==
180 FWL_STATE_CKB_Checked) { 180 FWL_STATE_CKB_Checked) {
181 return 1; 181 return 1;
182 } 182 }
183 return 0; 183 return 0;
184 } 184 }
185 FWL_ERR CFWL_CheckBoxImp::SetCheckState(int32_t iCheck) { 185 FWL_Error CFWL_CheckBoxImp::SetCheckState(int32_t iCheck) {
186 m_pProperties->m_dwStates &= ~FWL_STATE_CKB_CheckMask; 186 m_pProperties->m_dwStates &= ~FWL_STATE_CKB_CheckMask;
187 switch (iCheck) { 187 switch (iCheck) {
188 case 0: { 188 case 0: {
189 break; 189 break;
190 } 190 }
191 case 1: { 191 case 1: {
192 m_pProperties->m_dwStates |= FWL_STATE_CKB_Checked; 192 m_pProperties->m_dwStates |= FWL_STATE_CKB_Checked;
193 break; 193 break;
194 } 194 }
195 case 2: { 195 case 2: {
196 if (m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_3State) { 196 if (m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_3State) {
197 m_pProperties->m_dwStates |= FWL_STATE_CKB_Neutral; 197 m_pProperties->m_dwStates |= FWL_STATE_CKB_Neutral;
198 } 198 }
199 break; 199 break;
200 } 200 }
201 default: {} 201 default: {}
202 } 202 }
203 Repaint(&m_rtClient); 203 Repaint(&m_rtClient);
204 return FWL_ERR_Succeeded; 204 return FWL_Error::Succeeded;
205 } 205 }
206 void CFWL_CheckBoxImp::Layout() { 206 void CFWL_CheckBoxImp::Layout() {
207 int32_t width = int32_t(m_pProperties->m_rtWidget.width + 0.5f); 207 int32_t width = int32_t(m_pProperties->m_rtWidget.width + 0.5f);
208 int32_t height = int32_t(m_pProperties->m_rtWidget.height + 0.5f); 208 int32_t height = int32_t(m_pProperties->m_rtWidget.height + 0.5f);
209 m_pProperties->m_rtWidget.width = (FX_FLOAT)width; 209 m_pProperties->m_rtWidget.width = (FX_FLOAT)width;
210 m_pProperties->m_rtWidget.height = (FX_FLOAT)height; 210 m_pProperties->m_rtWidget.height = (FX_FLOAT)height;
211 GetClientRect(m_rtClient); 211 GetClientRect(m_rtClient);
212 FX_FLOAT fBoxTop = m_rtClient.top; 212 FX_FLOAT fBoxTop = m_rtClient.top;
213 FX_FLOAT fBoxLeft = m_rtClient.left; 213 FX_FLOAT fBoxLeft = m_rtClient.left;
214 FX_FLOAT fTextLeft = 0.0, fTextRight = 0.0; 214 FX_FLOAT fTextLeft = 0.0, fTextRight = 0.0;
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
406 uint32_t dwLaststate = m_pProperties->m_dwStates; 406 uint32_t dwLaststate = m_pProperties->m_dwStates;
407 if (dwFirststate != dwLaststate) { 407 if (dwFirststate != dwLaststate) {
408 CFWL_EvtCkbCheckStateChanged wmCheckBoxState; 408 CFWL_EvtCkbCheckStateChanged wmCheckBoxState;
409 wmCheckBoxState.m_pSrcTarget = m_pInterface; 409 wmCheckBoxState.m_pSrcTarget = m_pInterface;
410 DispatchEvent(&wmCheckBoxState); 410 DispatchEvent(&wmCheckBoxState);
411 } 411 }
412 } 412 }
413 CFWL_CheckBoxImpDelegate::CFWL_CheckBoxImpDelegate(CFWL_CheckBoxImp* pOwner) 413 CFWL_CheckBoxImpDelegate::CFWL_CheckBoxImpDelegate(CFWL_CheckBoxImp* pOwner)
414 : m_pOwner(pOwner) {} 414 : m_pOwner(pOwner) {}
415 415
416 int32_t CFWL_CheckBoxImpDelegate::OnProcessMessage(CFWL_Message* pMessage) { 416 void CFWL_CheckBoxImpDelegate::OnProcessMessage(CFWL_Message* pMessage) {
417 if (!pMessage) 417 if (!pMessage)
418 return 0; 418 return;
419 419
420 int32_t iRet = 1;
421 switch (pMessage->GetClassID()) { 420 switch (pMessage->GetClassID()) {
422 case CFWL_MessageType::Activate: { 421 case CFWL_MessageType::Activate: {
423 OnActivate(pMessage); 422 OnActivate(pMessage);
424 break; 423 break;
425 } 424 }
426 case CFWL_MessageType::SetFocus: { 425 case CFWL_MessageType::SetFocus: {
427 OnFocusChanged(pMessage, TRUE); 426 OnFocusChanged(pMessage, TRUE);
428 break; 427 break;
429 } 428 }
430 case CFWL_MessageType::KillFocus: { 429 case CFWL_MessageType::KillFocus: {
(...skipping 24 matching lines...) Expand all
455 } 454 }
456 break; 455 break;
457 } 456 }
458 case CFWL_MessageType::Key: { 457 case CFWL_MessageType::Key: {
459 CFWL_MsgKey* pKey = static_cast<CFWL_MsgKey*>(pMessage); 458 CFWL_MsgKey* pKey = static_cast<CFWL_MsgKey*>(pMessage);
460 if (pKey->m_dwCmd == FWL_KeyCommand::KeyDown) 459 if (pKey->m_dwCmd == FWL_KeyCommand::KeyDown)
461 OnKeyDown(pKey); 460 OnKeyDown(pKey);
462 break; 461 break;
463 } 462 }
464 default: { 463 default: {
465 iRet = 0;
466 break; 464 break;
467 } 465 }
468 } 466 }
469 467
470 CFWL_WidgetImpDelegate::OnProcessMessage(pMessage); 468 CFWL_WidgetImpDelegate::OnProcessMessage(pMessage);
471 return iRet;
472 } 469 }
473 FWL_ERR CFWL_CheckBoxImpDelegate::OnDrawWidget(CFX_Graphics* pGraphics, 470
474 const CFX_Matrix* pMatrix) { 471 void CFWL_CheckBoxImpDelegate::OnDrawWidget(CFX_Graphics* pGraphics,
475 return m_pOwner->DrawWidget(pGraphics, pMatrix); 472 const CFX_Matrix* pMatrix) {
473 m_pOwner->DrawWidget(pGraphics, pMatrix);
476 } 474 }
475
477 void CFWL_CheckBoxImpDelegate::OnActivate(CFWL_Message* pMsg) { 476 void CFWL_CheckBoxImpDelegate::OnActivate(CFWL_Message* pMsg) {
478 m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Deactivated; 477 m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Deactivated;
479 m_pOwner->Repaint(&(m_pOwner->m_rtClient)); 478 m_pOwner->Repaint(&(m_pOwner->m_rtClient));
480 } 479 }
481 void CFWL_CheckBoxImpDelegate::OnFocusChanged(CFWL_Message* pMsg, 480 void CFWL_CheckBoxImpDelegate::OnFocusChanged(CFWL_Message* pMsg,
482 FX_BOOL bSet) { 481 FX_BOOL bSet) {
483 if (bSet) { 482 if (bSet) {
484 m_pOwner->m_pProperties->m_dwStates |= FWL_WGTSTATE_Focused; 483 m_pOwner->m_pProperties->m_dwStates |= FWL_WGTSTATE_Focused;
485 } else { 484 } else {
486 m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Focused; 485 m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Focused;
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
559 void CFWL_CheckBoxImpDelegate::OnKeyDown(CFWL_MsgKey* pMsg) { 558 void CFWL_CheckBoxImpDelegate::OnKeyDown(CFWL_MsgKey* pMsg) {
560 if (pMsg->m_dwKeyCode == FWL_VKEY_Tab) { 559 if (pMsg->m_dwKeyCode == FWL_VKEY_Tab) {
561 m_pOwner->DispatchKeyEvent(pMsg); 560 m_pOwner->DispatchKeyEvent(pMsg);
562 return; 561 return;
563 } 562 }
564 if (pMsg->m_dwKeyCode == FWL_VKEY_Return || 563 if (pMsg->m_dwKeyCode == FWL_VKEY_Return ||
565 pMsg->m_dwKeyCode == FWL_VKEY_Space) { 564 pMsg->m_dwKeyCode == FWL_VKEY_Space) {
566 m_pOwner->NextStates(); 565 m_pOwner->NextStates();
567 } 566 }
568 } 567 }
OLDNEW
« no previous file with comments | « xfa/fwl/basewidget/fwl_checkboximp.h ('k') | xfa/fwl/basewidget/fwl_comboboximp.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698