diff options
Diffstat (limited to 'xfa/fxfa/cxfa_ffcheckbutton.cpp')
-rw-r--r-- | xfa/fxfa/cxfa_ffcheckbutton.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xfa/fxfa/cxfa_ffcheckbutton.cpp b/xfa/fxfa/cxfa_ffcheckbutton.cpp index 94fb9bd8a8..0b5bf53ef5 100644 --- a/xfa/fxfa/cxfa_ffcheckbutton.cpp +++ b/xfa/fxfa/cxfa_ffcheckbutton.cpp @@ -98,7 +98,7 @@ bool CXFA_FFCheckButton::PerformLayout() { XFA_AttributeEnum iCapPlacement = XFA_AttributeEnum::Unknown; float fCapReserve = 0; - CXFA_Caption* caption = m_pNode->GetCaption(); + CXFA_Caption* caption = m_pNode->GetCaptionIfExists(); if (caption && caption->IsVisible()) { m_rtCaption = rtWidget; iCapPlacement = caption->GetPlacementType(); @@ -122,7 +122,7 @@ bool CXFA_FFCheckButton::PerformLayout() { } m_rtUI = rtWidget; - CXFA_Margin* captionMargin = caption->GetMargin(); + CXFA_Margin* captionMargin = caption ? caption->GetMargin() : nullptr; switch (iCapPlacement) { case XFA_AttributeEnum::Left: { m_rtCaption.width = fCapReserve; |