summaryrefslogtreecommitdiff
path: root/xfa/src/fxfa
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2016-02-29 14:03:09 -0500
committerDan Sinclair <dsinclair@chromium.org>2016-02-29 14:03:09 -0500
commita74e9c9d3b0d98c5d6042d7ca739cd921a4524db (patch)
tree6d19df6011716727dfcc59f4ef902331de813db3 /xfa/src/fxfa
parenta5585569e274fcff8ae106e412eb764c2787cb3f (diff)
downloadpdfium-a74e9c9d3b0d98c5d6042d7ca739cd921a4524db.tar.xz
Using size_t to silence warnings.
Change a couple int32_t's to size_t in order to fix warnings on OSX. R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1747793002 .
Diffstat (limited to 'xfa/src/fxfa')
-rw-r--r--xfa/src/fxfa/src/app/xfa_fwltheme.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/xfa/src/fxfa/src/app/xfa_fwltheme.cpp b/xfa/src/fxfa/src/app/xfa_fwltheme.cpp
index f1aa18848d..851f9d6102 100644
--- a/xfa/src/fxfa/src/app/xfa_fwltheme.cpp
+++ b/xfa/src/fxfa/src/app/xfa_fwltheme.cpp
@@ -71,13 +71,12 @@ static const FX_WCHAR* g_FWLTheme_CalFonts[] = {
};
FWL_ERR CXFA_FWLTheme::Initialize() {
m_pTextOut = IFDE_TextOut::Create();
- for (int32_t i = 0; NULL == m_pCalendarFont &&
- i < sizeof(g_FWLTheme_CalFonts) / sizeof(const FX_WCHAR*);
- i++) {
+ for (size_t i = 0; !m_pCalendarFont && i < FX_ArraySize(g_FWLTheme_CalFonts);
+ ++i) {
m_pCalendarFont = IFX_Font::LoadFont(g_FWLTheme_CalFonts[i], 0, 0,
m_pApp->GetFDEFontMgr());
}
- if (NULL == m_pCalendarFont)
+ if (!m_pCalendarFont) {
#if _FXM_PLATFORM_ == _FXM_PLATFORM_WINDOWS_
m_pCalendarFont = m_pApp->GetFDEFontMgr()->GetDefFontByCodePage(
FX_CODEPAGE_MSWin_WesternEuropean, 0, NULL);
@@ -85,6 +84,8 @@ FWL_ERR CXFA_FWLTheme::Initialize() {
m_pCalendarFont = m_pApp->GetFDEFontMgr()->GetFontByCodePage(
FX_CODEPAGE_MSWin_WesternEuropean, 0, NULL);
#endif
+ }
+
FXSYS_assert(NULL != m_pCalendarFont);
FWLTHEME_Init();
return FWL_ERR_Succeeded;