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 #include "fpdfsdk/include/formfiller/FFL_CBA_Fontmap.h" | 7 #include "fpdfsdk/include/formfiller/FFL_CBA_Fontmap.h" |
8 #include "fpdfsdk/include/formfiller/FFL_ComboBox.h" | 8 #include "fpdfsdk/include/formfiller/FFL_ComboBox.h" |
9 #include "fpdfsdk/include/formfiller/FFL_FormFiller.h" | 9 #include "fpdfsdk/include/formfiller/FFL_FormFiller.h" |
10 #include "fpdfsdk/include/formfiller/FFL_IFormFiller.h" | 10 #include "fpdfsdk/include/formfiller/FFL_IFormFiller.h" |
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
258 | 258 |
259 #ifdef PDF_ENABLE_XFA | 259 #ifdef PDF_ENABLE_XFA |
260 FX_BOOL CFFL_ComboBox::IsFieldFull(CPDFSDK_PageView* pPageView) { | 260 FX_BOOL CFFL_ComboBox::IsFieldFull(CPDFSDK_PageView* pPageView) { |
261 if (CPWL_ComboBox* pComboBox = | 261 if (CPWL_ComboBox* pComboBox = |
262 static_cast<CPWL_ComboBox*>(GetPDFWindow(pPageView, FALSE))) { | 262 static_cast<CPWL_ComboBox*>(GetPDFWindow(pPageView, FALSE))) { |
263 if (CPWL_Edit* pEdit = pComboBox->GetEdit()) | 263 if (CPWL_Edit* pEdit = pComboBox->GetEdit()) |
264 return pEdit->IsTextFull(); | 264 return pEdit->IsTextFull(); |
265 } | 265 } |
266 return FALSE; | 266 return FALSE; |
267 } | 267 } |
| 268 #endif // PDF_ENABLE_XFA |
268 | 269 |
269 #endif | |
270 void CFFL_ComboBox::OnSetFocus(CPWL_Wnd* pWnd) { | 270 void CFFL_ComboBox::OnSetFocus(CPWL_Wnd* pWnd) { |
271 ASSERT(m_pApp != NULL); | 271 ASSERT(m_pApp != NULL); |
272 | 272 |
273 ASSERT(pWnd != NULL); | 273 ASSERT(pWnd != NULL); |
274 | 274 |
275 if (pWnd->GetClassName() == PWL_CLASSNAME_EDIT) { | 275 if (pWnd->GetClassName() == PWL_CLASSNAME_EDIT) { |
276 CPWL_Edit* pEdit = (CPWL_Edit*)pWnd; | 276 CPWL_Edit* pEdit = (CPWL_Edit*)pWnd; |
277 pEdit->SetCharSet(134); | 277 pEdit->SetCharSet(134); |
278 pEdit->SetCodePage(936); | 278 pEdit->SetCodePage(936); |
279 | 279 |
(...skipping 30 matching lines...) Expand all Loading... |
310 if (nExport >= 0) { | 310 if (nExport >= 0) { |
311 if (CPDF_FormField* pFormField = m_pWidget->GetFormField()) { | 311 if (CPDF_FormField* pFormField = m_pWidget->GetFormField()) { |
312 swRet = pFormField->GetOptionValue(nExport); | 312 swRet = pFormField->GetOptionValue(nExport); |
313 if (swRet.IsEmpty()) | 313 if (swRet.IsEmpty()) |
314 swRet = pFormField->GetOptionLabel(nExport); | 314 swRet = pFormField->GetOptionLabel(nExport); |
315 } | 315 } |
316 } | 316 } |
317 | 317 |
318 return swRet; | 318 return swRet; |
319 } | 319 } |
OLD | NEW |