| 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 "../../../include/fxge/fx_ge.h" | 7 #include "../../../include/fxge/fx_ge.h" |
| 8 #if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_ | 8 #if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_ |
| 9 #include "../../../include/fxge/fx_ge_win32.h" | 9 #include "../../../include/fxge/fx_ge_win32.h" |
| 10 #include "dwrite_int.h" | 10 #include "dwrite_int.h" |
| (...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 307 } | 307 } |
| 308 HRESULT STDMETHODCALLTYPE CDwFontFileStream::ReadFileFragment( | 308 HRESULT STDMETHODCALLTYPE CDwFontFileStream::ReadFileFragment( |
| 309 void const** fragmentStart, | 309 void const** fragmentStart, |
| 310 UINT64 fileOffset, | 310 UINT64 fileOffset, |
| 311 UINT64 fragmentSize, | 311 UINT64 fragmentSize, |
| 312 OUT void** fragmentContext | 312 OUT void** fragmentContext |
| 313 ) | 313 ) |
| 314 { | 314 { |
| 315 if (fileOffset <= resourceSize_ && | 315 if (fileOffset <= resourceSize_ && |
| 316 fragmentSize <= resourceSize_ - fileOffset) { | 316 fragmentSize <= resourceSize_ - fileOffset) { |
| 317 *fragmentStart = static_cast<FX_BYTE const*>(resourcePtr_) + static_cast
<size_t>(fileOffset); | 317 *fragmentStart = static_cast<uint8_t const*>(resourcePtr_) + static_cast
<size_t>(fileOffset); |
| 318 *fragmentContext = NULL; | 318 *fragmentContext = NULL; |
| 319 return S_OK; | 319 return S_OK; |
| 320 } else { | 320 } else { |
| 321 *fragmentStart = NULL; | 321 *fragmentStart = NULL; |
| 322 *fragmentContext = NULL; | 322 *fragmentContext = NULL; |
| 323 return E_FAIL; | 323 return E_FAIL; |
| 324 } | 324 } |
| 325 } | 325 } |
| 326 void STDMETHODCALLTYPE CDwFontFileStream::ReleaseFileFragment(void* fragmentCont
ext) | 326 void STDMETHODCALLTYPE CDwFontFileStream::ReleaseFileFragment(void* fragmentCont
ext) |
| 327 { | 327 { |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 471 text_bbox.Height(), | 471 text_bbox.Height(), |
| 472 &dib, | 472 &dib, |
| 473 text_bbox.left, | 473 text_bbox.left, |
| 474 text_bbox.top, | 474 text_bbox.top, |
| 475 FXDIB_BLEND_NORMAL, | 475 FXDIB_BLEND_NORMAL, |
| 476 pClipRgn | 476 pClipRgn |
| 477 ); | 477 ); |
| 478 return hr; | 478 return hr; |
| 479 } | 479 } |
| 480 #endif | 480 #endif |
| OLD | NEW |