OLD | NEW |
---|---|
1 // Copyright 2016 PDFium Authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_COLORSPACE_H_ | 7 #ifndef CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_COLORSPACE_H_ |
8 #define CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_COLORSPACE_H_ | 8 #define CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_COLORSPACE_H_ |
9 | |
Lei Zhang
2016/09/28 19:23:55
accidental line deletion?
Tom Sepez
2016/09/28 20:10:03
Yep. the only manual merge. done.
| |
10 #include <memory> | 9 #include <memory> |
11 | 10 |
12 #include "core/fxcrt/include/cfx_weak_ptr.h" | |
13 #include "core/fxcrt/include/fx_string.h" | 11 #include "core/fxcrt/include/fx_string.h" |
14 #include "core/fxcrt/include/fx_system.h" | 12 #include "core/fxcrt/include/fx_system.h" |
15 | 13 |
16 #define PDFCS_DEVICEGRAY 1 | 14 #define PDFCS_DEVICEGRAY 1 |
17 #define PDFCS_DEVICERGB 2 | 15 #define PDFCS_DEVICERGB 2 |
18 #define PDFCS_DEVICECMYK 3 | 16 #define PDFCS_DEVICECMYK 3 |
19 #define PDFCS_CALGRAY 4 | 17 #define PDFCS_CALGRAY 4 |
20 #define PDFCS_CALRGB 5 | 18 #define PDFCS_CALRGB 5 |
21 #define PDFCS_LAB 6 | 19 #define PDFCS_LAB 6 |
22 #define PDFCS_ICCBASED 7 | 20 #define PDFCS_ICCBASED 7 |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
98 FX_FLOAT m, | 96 FX_FLOAT m, |
99 FX_FLOAT y, | 97 FX_FLOAT y, |
100 FX_FLOAT k) const; | 98 FX_FLOAT k) const; |
101 | 99 |
102 int m_Family; | 100 int m_Family; |
103 uint32_t m_nComponents; | 101 uint32_t m_nComponents; |
104 CPDF_Array* m_pArray; | 102 CPDF_Array* m_pArray; |
105 uint32_t m_dwStdConversion; | 103 uint32_t m_dwStdConversion; |
106 }; | 104 }; |
107 | 105 |
108 using CPDF_CountedColorSpace = CFX_WeakPtr<CPDF_ColorSpace>::Handle; | |
109 | |
110 namespace std { | 106 namespace std { |
111 | 107 |
112 // Make std::unique_ptr<CPDF_ColorSpace> call Release() rather than | 108 // Make std::unique_ptr<CPDF_ColorSpace> call Release() rather than |
113 // simply deleting the object. | 109 // simply deleting the object. |
114 template <> | 110 template <> |
115 struct default_delete<CPDF_ColorSpace> { | 111 struct default_delete<CPDF_ColorSpace> { |
116 void operator()(CPDF_ColorSpace* pColorSpace) const { | 112 void operator()(CPDF_ColorSpace* pColorSpace) const { |
117 if (pColorSpace) | 113 if (pColorSpace) |
118 pColorSpace->Release(); | 114 pColorSpace->Release(); |
119 } | 115 } |
120 }; | 116 }; |
121 | 117 |
122 } // namespace std | 118 } // namespace std |
123 | 119 |
124 #endif // CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_COLORSPACE_H_ | 120 #endif // CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_COLORSPACE_H_ |
OLD | NEW |