From 2501ae2474c1f097a06634d647de2eb3fb730864 Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Mon, 20 Nov 2017 21:19:13 +0000 Subject: Remove CXFA_DataData operator bool override This CL removes CXFA_DataData::operator bool in favour of an explicit HasValidNode method. This makes the call sites a lot clearer. Change-Id: I6fae14fdeec4674ca7916e21b9e5703070fc3069 Reviewed-on: https://pdfium-review.googlesource.com/18830 Commit-Queue: dsinclair Reviewed-by: Ryan Harrison --- xfa/fwl/theme/cfwl_edittp.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'xfa/fwl') diff --git a/xfa/fwl/theme/cfwl_edittp.cpp b/xfa/fwl/theme/cfwl_edittp.cpp index 4f8c4d533e..563ae532dd 100644 --- a/xfa/fwl/theme/cfwl_edittp.cpp +++ b/xfa/fwl/theme/cfwl_edittp.cpp @@ -24,9 +24,9 @@ void CFWL_EditTP::DrawBackground(CFWL_ThemeBackground* pParams) { CXFA_BorderData borderUIData = pWidget->GetDataAcc()->GetUIBorderData(); FX_ARGB cr = 0xFF000000; float fWidth = 1.0f; - if (borderUIData) { + if (borderUIData.HasValidNode()) { CXFA_EdgeData edgeData = borderUIData.GetEdgeData(0); - if (edgeData) { + if (edgeData.HasValidNode()) { cr = edgeData.GetColor(); fWidth = edgeData.GetThickness(); } -- cgit v1.2.3