From b3ea5b41a3f472fe2b3ecf68129382b51ede6c3a Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Tue, 8 Dec 2015 11:30:34 -0800 Subject: Make app.cpp match XFA Master side change for https://codereview.chromium.org/1504413002 R=thestig@chromium.org Review URL: https://codereview.chromium.org/1508133003 . --- fpdfsdk/src/javascript/app.cpp | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/fpdfsdk/src/javascript/app.cpp b/fpdfsdk/src/javascript/app.cpp index 205673e6d5..70ce771090 100644 --- a/fpdfsdk/src/javascript/app.cpp +++ b/fpdfsdk/src/javascript/app.cpp @@ -196,7 +196,6 @@ FX_BOOL app::viewerVersion(IJS_Context* cc, CFX_WideString& sError) { if (!vp.IsGetting()) return FALSE; - vp << JS_NUM_VIEWERVERSION; return TRUE; } @@ -204,23 +203,19 @@ FX_BOOL app::viewerVersion(IJS_Context* cc, FX_BOOL app::platform(IJS_Context* cc, CJS_PropValue& vp, CFX_WideString& sError) { - if (vp.IsGetting()) { - vp << JS_STR_PLATFORM; - return TRUE; - } - - return FALSE; + if (!vp.IsGetting()) + return FALSE; + vp << JS_STR_PLATFORM; + return TRUE; } FX_BOOL app::language(IJS_Context* cc, CJS_PropValue& vp, CFX_WideString& sError) { - if (vp.IsGetting()) { - vp << JS_STR_LANGUANGE; - return TRUE; - } - - return FALSE; + if (!vp.IsGetting()) + return FALSE; + vp << JS_STR_LANGUANGE; + return TRUE; } // creates a new fdf object that contains no data -- cgit v1.2.3