| OLD | NEW |
| 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 "public/fpdf_edit.h" | 7 #include "public/fpdf_edit.h" |
| 8 | 8 |
| 9 #include "fpdfsdk/include/fsdk_define.h" | 9 #include "fpdfsdk/include/fsdk_define.h" |
| 10 #include "public/fpdf_formfill.h" | 10 #include "public/fpdf_formfill.h" |
| (...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 209 return TRUE; | 209 return TRUE; |
| 210 | 210 |
| 211 CPDF_Dictionary* pSMaskDict = | 211 CPDF_Dictionary* pSMaskDict = |
| 212 pGeneralState ? ToDictionary(pGeneralState->m_pSoftMask) : NULL; | 212 pGeneralState ? ToDictionary(pGeneralState->m_pSoftMask) : NULL; |
| 213 if (pSMaskDict) | 213 if (pSMaskDict) |
| 214 return TRUE; | 214 return TRUE; |
| 215 | 215 |
| 216 if (pGeneralState && pGeneralState->m_FillAlpha != 1.0f) | 216 if (pGeneralState && pGeneralState->m_FillAlpha != 1.0f) |
| 217 return TRUE; | 217 return TRUE; |
| 218 | 218 |
| 219 if (pPageObj->m_Type == PDFPAGE_PATH) { | 219 if (pPageObj->m_Type == CPDF_PageObject::PATH) { |
| 220 if (pGeneralState && pGeneralState->m_StrokeAlpha != 1.0f) | 220 if (pGeneralState && pGeneralState->m_StrokeAlpha != 1.0f) |
| 221 return TRUE; | 221 return TRUE; |
| 222 } | 222 } |
| 223 | 223 |
| 224 if (pPageObj->m_Type == PDFPAGE_FORM) { | 224 if (pPageObj->m_Type == CPDF_PageObject::FORM) { |
| 225 CPDF_FormObject* pFormObj = (CPDF_FormObject*)pPageObj; | 225 CPDF_FormObject* pFormObj = (CPDF_FormObject*)pPageObj; |
| 226 if (pFormObj->m_pForm && | 226 if (pFormObj->m_pForm && |
| 227 (pFormObj->m_pForm->m_Transparency & PDFTRANS_ISOLATED)) | 227 (pFormObj->m_pForm->m_Transparency & PDFTRANS_ISOLATED)) |
| 228 return TRUE; | 228 return TRUE; |
| 229 if (pFormObj->m_pForm && | 229 if (pFormObj->m_pForm && |
| 230 (!(pFormObj->m_pForm->m_Transparency & PDFTRANS_ISOLATED) && | 230 (!(pFormObj->m_pForm->m_Transparency & PDFTRANS_ISOLATED) && |
| 231 (pFormObj->m_pForm->m_Transparency & PDFTRANS_GROUP))) | 231 (pFormObj->m_pForm->m_Transparency & PDFTRANS_GROUP))) |
| 232 return TRUE; | 232 return TRUE; |
| 233 } | 233 } |
| 234 return FALSE; | 234 return FALSE; |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 !pPage->m_pFormDict->GetElement("Type")->GetDirect() || | 303 !pPage->m_pFormDict->GetElement("Type")->GetDirect() || |
| 304 pPage->m_pFormDict->GetElement("Type")->GetDirect()->GetString().Compare( | 304 pPage->m_pFormDict->GetElement("Type")->GetDirect()->GetString().Compare( |
| 305 "Page")) { | 305 "Page")) { |
| 306 return; | 306 return; |
| 307 } | 307 } |
| 308 CPDF_Dictionary* pDict = pPage->m_pFormDict; | 308 CPDF_Dictionary* pDict = pPage->m_pFormDict; |
| 309 rotate %= 4; | 309 rotate %= 4; |
| 310 | 310 |
| 311 pDict->SetAt("Rotate", new CPDF_Number(rotate * 90)); | 311 pDict->SetAt("Rotate", new CPDF_Number(rotate * 90)); |
| 312 } | 312 } |
| OLD | NEW |