summaryrefslogtreecommitdiff
path: root/xfa/fxfa
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/fxfa')
-rw-r--r--xfa/fxfa/app/xfa_fftextedit.cpp7
-rw-r--r--xfa/fxfa/parser/xfa_localevalue.cpp3
2 files changed, 5 insertions, 5 deletions
diff --git a/xfa/fxfa/app/xfa_fftextedit.cpp b/xfa/fxfa/app/xfa_fftextedit.cpp
index 094839f486..50685c7e40 100644
--- a/xfa/fxfa/app/xfa_fftextedit.cpp
+++ b/xfa/fxfa/app/xfa_fftextedit.cpp
@@ -522,9 +522,8 @@ bool CXFA_FFDateTimeEdit::LoadWidget() {
if (!wsText.IsEmpty()) {
CXFA_LocaleValue lcValue = XFA_GetLocaleValue(m_pDataAcc);
CFX_Unitime date = lcValue.GetDate();
- if ((FX_UNITIME)date != 0) {
+ if (date.ToInt64() != 0)
pWidget->SetCurSel(date.GetYear(), date.GetMonth(), date.GetDay());
- }
}
} break;
default:
@@ -620,7 +619,7 @@ bool CXFA_FFDateTimeEdit::UpdateFWLData() {
CXFA_LocaleValue lcValue = XFA_GetLocaleValue(m_pDataAcc);
CFX_Unitime date = lcValue.GetDate();
if (lcValue.IsValid()) {
- if ((FX_UNITIME)date != 0) {
+ if (date.ToInt64() != 0) {
((CFWL_DateTimePicker*)m_pNormalWidget)
->SetCurSel(date.GetYear(), date.GetMonth(), date.GetDay());
}
@@ -648,7 +647,7 @@ void CXFA_FFDateTimeEdit::OnSelectChanged(CFWL_Widget* pWidget,
m_pDataAcc->GetPictureContent(wsPicture, XFA_VALUEPICTURE_Edit);
CXFA_LocaleValue date(XFA_VT_DATE, GetDoc()->GetXFADoc()->GetLocalMgr());
CFX_Unitime dt;
- dt.Set(iYear, iMonth, iDay);
+ dt.Set(iYear, iMonth, iDay, 0, 0, 0, 0);
date.SetDate(dt);
CFX_WideString wsDate;
date.FormatPatterns(wsDate, wsPicture, m_pDataAcc->GetLocal(),
diff --git a/xfa/fxfa/parser/xfa_localevalue.cpp b/xfa/fxfa/parser/xfa_localevalue.cpp
index 1012896089..cddfff3134 100644
--- a/xfa/fxfa/parser/xfa_localevalue.cpp
+++ b/xfa/fxfa/parser/xfa_localevalue.cpp
@@ -672,7 +672,8 @@ bool CXFA_LocaleValue::ValidateCanonicalDate(const CFX_WideString& wsDate,
return false;
}
CFX_Unitime ut;
- ut.Set(wYear, static_cast<uint8_t>(wMonth), static_cast<uint8_t>(wDay));
+ ut.Set(wYear, static_cast<uint8_t>(wMonth), static_cast<uint8_t>(wDay), 0, 0,
+ 0, 0);
unDate = unDate + ut;
return true;
}