Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(108)

Side by Side Diff: core/fpdfdoc/doc_ocg.cpp

Issue 2183313004: Split fpdfdoc/include/fpdf_doc.h into individual classes. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: review feedback Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « core/fpdfdoc/doc_metadata.cpp ('k') | core/fpdfdoc/doc_utils.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include "core/fpdfdoc/include/cpdf_occontext.h"
8
7 #include "core/fpdfapi/fpdf_page/cpdf_contentmarkdata.h" 9 #include "core/fpdfapi/fpdf_page/cpdf_contentmarkdata.h"
8 #include "core/fpdfapi/fpdf_page/include/cpdf_pageobject.h" 10 #include "core/fpdfapi/fpdf_page/include/cpdf_pageobject.h"
9 #include "core/fpdfapi/fpdf_parser/include/cpdf_array.h" 11 #include "core/fpdfapi/fpdf_parser/include/cpdf_array.h"
10 #include "core/fpdfapi/fpdf_parser/include/cpdf_document.h" 12 #include "core/fpdfapi/fpdf_parser/include/cpdf_document.h"
11 #include "core/fpdfdoc/include/fpdf_doc.h"
12 13
13 namespace { 14 namespace {
14 15
15 int32_t FPDFDOC_OCG_FindGroup(const CPDF_Array* pArray, 16 int32_t FPDFDOC_OCG_FindGroup(const CPDF_Array* pArray,
16 const CPDF_Dictionary* pGroupDict) { 17 const CPDF_Dictionary* pGroupDict) {
17 if (!pArray || !pGroupDict) 18 if (!pArray || !pGroupDict)
18 return -1; 19 return -1;
19 20
20 for (size_t i = 0; i < pArray->GetCount(); i++) { 21 for (size_t i = 0; i < pArray->GetCount(); i++) {
21 if (pArray->GetDictAt(i) == pGroupDict) 22 if (pArray->GetDictAt(i) == pGroupDict)
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 276
276 bool CPDF_OCContext::CheckOCGVisible(const CPDF_Dictionary* pOCGDict) { 277 bool CPDF_OCContext::CheckOCGVisible(const CPDF_Dictionary* pOCGDict) {
277 if (!pOCGDict) 278 if (!pOCGDict)
278 return true; 279 return true;
279 280
280 CFX_ByteString csType = pOCGDict->GetStringBy("Type", "OCG"); 281 CFX_ByteString csType = pOCGDict->GetStringBy("Type", "OCG");
281 if (csType == "OCG") 282 if (csType == "OCG")
282 return GetOCGVisible(pOCGDict); 283 return GetOCGVisible(pOCGDict);
283 return LoadOCMDState(pOCGDict); 284 return LoadOCMDState(pOCGDict);
284 } 285 }
OLDNEW
« no previous file with comments | « core/fpdfdoc/doc_metadata.cpp ('k') | core/fpdfdoc/doc_utils.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698