| 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 "../../core/include/fxcodec/fx_codec.h" | 7 #include "../../core/include/fxcodec/fx_codec.h" |
| 8 #include "../../core/include/fxcrt/fx_safe_types.h" | 8 #include "../../core/include/fxcrt/fx_safe_types.h" |
| 9 #include "../../public/fpdf_ext.h" | 9 #include "../../public/fpdf_ext.h" |
| 10 #include "../../public/fpdf_progressive.h" | 10 #include "../../public/fpdf_progressive.h" |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 | 54 |
| 55 FPDF_BOOL FSDK_IsSandBoxPolicyEnabled(FPDF_DWORD policy) { | 55 FPDF_BOOL FSDK_IsSandBoxPolicyEnabled(FPDF_DWORD policy) { |
| 56 switch (policy) { | 56 switch (policy) { |
| 57 case FPDF_POLICY_MACHINETIME_ACCESS: | 57 case FPDF_POLICY_MACHINETIME_ACCESS: |
| 58 return (foxit_sandbox_policy & 0x01) ? TRUE : FALSE; | 58 return (foxit_sandbox_policy & 0x01) ? TRUE : FALSE; |
| 59 default: | 59 default: |
| 60 return FALSE; | 60 return FALSE; |
| 61 } | 61 } |
| 62 } | 62 } |
| 63 | 63 |
| 64 #ifndef _T | |
| 65 #define _T(x) x | |
| 66 #endif | |
| 67 | |
| 68 CCodec_ModuleMgr* g_pCodecModule = nullptr; | 64 CCodec_ModuleMgr* g_pCodecModule = nullptr; |
| 69 | 65 |
| 70 #if _FX_OS_ == _FX_LINUX_EMBEDDED_ | 66 #if _FX_OS_ == _FX_LINUX_EMBEDDED_ |
| 71 class CFontMapper : public IPDF_FontMapper { | 67 class CFontMapper : public IPDF_FontMapper { |
| 72 public: | 68 public: |
| 73 CFontMapper(); | 69 CFontMapper(); |
| 74 ~CFontMapper() override; | 70 ~CFontMapper() override; |
| 75 | 71 |
| 76 // IPDF_FontMapper | 72 // IPDF_FontMapper |
| 77 FT_Face FindSubstFont( | 73 FT_Face FindSubstFont( |
| (...skipping 835 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 913 if (!buffer) { | 909 if (!buffer) { |
| 914 *buflen = len; | 910 *buflen = len; |
| 915 } else if (*buflen >= len) { | 911 } else if (*buflen >= len) { |
| 916 memcpy(buffer, utf16Name.c_str(), len); | 912 memcpy(buffer, utf16Name.c_str(), len); |
| 917 *buflen = len; | 913 *buflen = len; |
| 918 } else { | 914 } else { |
| 919 *buflen = -1; | 915 *buflen = -1; |
| 920 } | 916 } |
| 921 return (FPDF_DEST)pDestObj; | 917 return (FPDF_DEST)pDestObj; |
| 922 } | 918 } |
| OLD | NEW |