summaryrefslogtreecommitdiff
path: root/core/fpdfdoc/cpdf_viewerpreferences.h
diff options
context:
space:
mode:
authorthestig <thestig@chromium.org>2016-11-04 16:07:25 -0700
committerCommit bot <commit-bot@chromium.org>2016-11-04 16:07:25 -0700
commit04bebfe590d6d27a825b881fd234e31501843edc (patch)
tree127477b084005457579c599b2ec9eef0668a1479 /core/fpdfdoc/cpdf_viewerpreferences.h
parent931d087b991a986cc8bfa72131fe8eda0d987fc4 (diff)
downloadpdfium-04bebfe590d6d27a825b881fd234e31501843edc.tar.xz
Implement FPDF_VIEWERREF_GetName() API.chromium/2910
This is a generic API function to retrieve any viewer preference of type name. BUG=pdfium:414 Review-Url: https://codereview.chromium.org/2475923003
Diffstat (limited to 'core/fpdfdoc/cpdf_viewerpreferences.h')
-rw-r--r--core/fpdfdoc/cpdf_viewerpreferences.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/fpdfdoc/cpdf_viewerpreferences.h b/core/fpdfdoc/cpdf_viewerpreferences.h
index c64292d9f9..c7e9112380 100644
--- a/core/fpdfdoc/cpdf_viewerpreferences.h
+++ b/core/fpdfdoc/cpdf_viewerpreferences.h
@@ -25,6 +25,11 @@ class CPDF_ViewerPreferences {
CPDF_Array* PrintPageRange() const;
CFX_ByteString Duplex() const;
+ // Gets the entry for |bsKey|. If the entry exists and it is of type name,
+ // then this method writes the value into |bsVal| and returns true. Otherwise
+ // returns false and |bsVal| is untouched. |bsVal| must not be NULL.
+ bool GenericName(const CFX_ByteString& bsKey, CFX_ByteString* bsVal) const;
+
private:
CPDF_Dictionary* GetViewerPreferences() const;