Index: xfa/fxfa/app/xfa_fftextedit.cpp |
diff --git a/xfa/fxfa/app/xfa_fftextedit.cpp b/xfa/fxfa/app/xfa_fftextedit.cpp |
index fd2abe7aba4134cca9071644fbb7a05a79801826..d29446a0867d944d692385c8a70a998c3faa3f67 100644 |
--- a/xfa/fxfa/app/xfa_fftextedit.cpp |
+++ b/xfa/fxfa/app/xfa_fftextedit.cpp |
@@ -75,9 +75,9 @@ void CXFA_FFTextEdit::UpdateWidgetProperty() { |
dwExtendedStyle |= FWL_STYLEEXT_EDT_ReadOnly; |
dwExtendedStyle |= FWL_STYLEEXT_EDT_MultiLine; |
} |
- XFA_ELEMENT eType = XFA_ELEMENT_UNKNOWN; |
+ XFA_Element eType = XFA_Element::Unknown; |
int32_t iMaxChars = m_pDataAcc->GetMaxChars(eType); |
- if (eType == XFA_ELEMENT_ExData) { |
+ if (eType == XFA_Element::ExData) { |
iMaxChars = 0; |
} |
int32_t iNumCells = m_pDataAcc->GetNumberOfCells(); |
@@ -189,7 +189,7 @@ FX_BOOL CXFA_FFTextEdit::CommitData() { |
} |
void CXFA_FFTextEdit::ValidateNumberField(const CFX_WideString& wsText) { |
CXFA_WidgetAcc* pAcc = GetDataAcc(); |
- if (pAcc && pAcc->GetUIType() == XFA_ELEMENT_NumericEdit) { |
+ if (pAcc && pAcc->GetUIType() == XFA_Element::NumericEdit) { |
IXFA_AppProvider* pAppProvider = GetApp()->GetAppProvider(); |
if (pAppProvider) { |
CFX_WideString wsTitle; |
@@ -253,11 +253,11 @@ FX_BOOL CXFA_FFTextEdit::UpdateFWLData() { |
eType = XFA_VALUEPICTURE_Edit; |
} |
FX_BOOL bUpdate = FALSE; |
- if (m_pDataAcc->GetUIType() == XFA_ELEMENT_TextEdit && |
+ if (m_pDataAcc->GetUIType() == XFA_Element::TextEdit && |
m_pDataAcc->GetNumberOfCells() < 0) { |
- XFA_ELEMENT elementType = XFA_ELEMENT_UNKNOWN; |
+ XFA_Element elementType = XFA_Element::Unknown; |
int32_t iMaxChars = m_pDataAcc->GetMaxChars(elementType); |
- if (elementType == XFA_ELEMENT_ExData) { |
+ if (elementType == XFA_Element::ExData) { |
iMaxChars = eType == XFA_VALUEPICTURE_Edit ? iMaxChars : 0; |
} |
if (((CFWL_Edit*)m_pNormalWidget)->GetLimit() != iMaxChars) { |
@@ -265,7 +265,7 @@ FX_BOOL CXFA_FFTextEdit::UpdateFWLData() { |
bUpdate = TRUE; |
} |
} |
- if (m_pDataAcc->GetUIType() == XFA_ELEMENT_Barcode) { |
+ if (m_pDataAcc->GetUIType() == XFA_Element::Barcode) { |
int32_t nDataLen = 0; |
if (eType == XFA_VALUEPICTURE_Edit) |
m_pDataAcc->GetBarcodeAttribute_DataLength(nDataLen); |
@@ -337,7 +337,7 @@ FX_BOOL CXFA_FFTextEdit::DeSelect() { |
FX_BOOL CXFA_FFTextEdit::GetSuggestWords( |
CFX_PointF pointf, |
std::vector<CFX_ByteString>& sSuggest) { |
- if (m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) { |
+ if (m_pDataAcc->GetUIType() != XFA_Element::TextEdit) { |
return FALSE; |
} |
FWLToClient(pointf.x, pointf.y); |
@@ -346,7 +346,7 @@ FX_BOOL CXFA_FFTextEdit::GetSuggestWords( |
FX_BOOL CXFA_FFTextEdit::ReplaceSpellCheckWord( |
CFX_PointF pointf, |
const CFX_ByteStringC& bsReplace) { |
- if (m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) { |
+ if (m_pDataAcc->GetUIType() != XFA_Element::TextEdit) { |
return FALSE; |
} |
FWLToClient(pointf.x, pointf.y); |
@@ -363,7 +363,7 @@ void CXFA_FFTextEdit::OnTextChanged(IFWL_Widget* pWidget, |
eParam.m_pTarget = m_pDataAcc; |
eParam.m_wsPrevText = wsPrevText; |
CFWL_Edit* pEdit = ((CFWL_Edit*)m_pNormalWidget); |
- if (m_pDataAcc->GetUIType() == XFA_ELEMENT_DateTimeEdit) { |
+ if (m_pDataAcc->GetUIType() == XFA_Element::DateTimeEdit) { |
CFWL_DateTimePicker* pDateTime = (CFWL_DateTimePicker*)pEdit; |
pDateTime->GetEditText(eParam.m_wsNewText); |
int32_t iSels = pDateTime->CountSelRanges(); |
@@ -387,7 +387,7 @@ void CXFA_FFTextEdit::OnTextFull(IFWL_Widget* pWidget) { |
} |
FX_BOOL CXFA_FFTextEdit::CheckWord(const CFX_ByteStringC& sWord) { |
- if (sWord.IsEmpty() || m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) { |
+ if (sWord.IsEmpty() || m_pDataAcc->GetUIType() != XFA_Element::TextEdit) { |
return TRUE; |
} |
return GetDoc()->GetDocProvider()->CheckWord(GetDoc(), sWord); |
@@ -395,7 +395,7 @@ FX_BOOL CXFA_FFTextEdit::CheckWord(const CFX_ByteStringC& sWord) { |
FX_BOOL CXFA_FFTextEdit::GetSuggestWords( |
const CFX_ByteStringC& sWord, |
std::vector<CFX_ByteString>& sSuggest) { |
- if (m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) { |
+ if (m_pDataAcc->GetUIType() != XFA_Element::TextEdit) { |
return FALSE; |
} |
return GetDoc()->GetDocProvider()->GetSuggestWords(GetDoc(), sWord, sSuggest); |
@@ -600,7 +600,7 @@ FX_BOOL CXFA_FFDateTimeEdit::LoadWidget() { |
pWidget->SetEditText(wsText); |
if (CXFA_Value value = m_pDataAcc->GetFormValue()) { |
switch (value.GetChildValueClassID()) { |
- case XFA_ELEMENT_Date: { |
+ case XFA_Element::Date: { |
if (!wsText.IsEmpty()) { |
CXFA_LocaleValue lcValue = XFA_GetLocaleValue(m_pDataAcc); |
CFX_Unitime date = lcValue.GetDate(); |