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 <limits.h> | 7 #include <limits.h> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "../../../../third_party/base/nonstd_unique_ptr.h" | |
11 #include "../../../../third_party/base/numerics/safe_conversions_impl.h" | |
12 #include "../../../include/fpdfapi/fpdf_module.h" | 10 #include "../../../include/fpdfapi/fpdf_module.h" |
13 #include "../../../include/fpdfapi/fpdf_page.h" | 11 #include "../../../include/fpdfapi/fpdf_page.h" |
14 #include "../../../include/fxcrt/fx_safe_types.h" | 12 #include "../../../include/fxcrt/fx_safe_types.h" |
15 #include "pageint.h" | 13 #include "pageint.h" |
| 14 #include "third_party/base/nonstd_unique_ptr.h" |
| 15 #include "third_party/base/numerics/safe_conversions_impl.h" |
16 | 16 |
17 class CPDF_PSEngine; | 17 class CPDF_PSEngine; |
18 typedef enum { | 18 typedef enum { |
19 PSOP_ADD, | 19 PSOP_ADD, |
20 PSOP_SUB, | 20 PSOP_SUB, |
21 PSOP_MUL, | 21 PSOP_MUL, |
22 PSOP_DIV, | 22 PSOP_DIV, |
23 PSOP_IDIV, | 23 PSOP_IDIV, |
24 PSOP_MOD, | 24 PSOP_MOD, |
25 PSOP_NEG, | 25 PSOP_NEG, |
(...skipping 890 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
916 for (int i = 0; i < m_nOutputs; i++) { | 916 for (int i = 0; i < m_nOutputs; i++) { |
917 if (results[i] < m_pRanges[i * 2]) { | 917 if (results[i] < m_pRanges[i * 2]) { |
918 results[i] = m_pRanges[i * 2]; | 918 results[i] = m_pRanges[i * 2]; |
919 } else if (results[i] > m_pRanges[i * 2 + 1]) { | 919 } else if (results[i] > m_pRanges[i * 2 + 1]) { |
920 results[i] = m_pRanges[i * 2 + 1]; | 920 results[i] = m_pRanges[i * 2 + 1]; |
921 } | 921 } |
922 } | 922 } |
923 } | 923 } |
924 return TRUE; | 924 return TRUE; |
925 } | 925 } |
OLD | NEW |