| 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/fpdfview.h" |     7 #include "public/fpdfview.h" | 
|     8  |     8  | 
|     9 #include <memory> |     9 #include <memory> | 
|    10  |    10  | 
| (...skipping 878 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   889   pContext->m_pDevice->SetClip_Rect( |   889   pContext->m_pDevice->SetClip_Rect( | 
|   890       FX_RECT(start_x, start_y, start_x + size_x, start_y + size_y)); |   890       FX_RECT(start_x, start_y, start_x + size_x, start_y + size_y)); | 
|   891  |   891  | 
|   892   pContext->m_pContext.reset(new CPDF_RenderContext(pPage)); |   892   pContext->m_pContext.reset(new CPDF_RenderContext(pPage)); | 
|   893   pContext->m_pContext->AppendLayer(pPage, &matrix); |   893   pContext->m_pContext->AppendLayer(pPage, &matrix); | 
|   894  |   894  | 
|   895   if (flags & FPDF_ANNOT) { |   895   if (flags & FPDF_ANNOT) { | 
|   896     pContext->m_pAnnots.reset(new CPDF_AnnotList(pPage)); |   896     pContext->m_pAnnots.reset(new CPDF_AnnotList(pPage)); | 
|   897     FX_BOOL bPrinting = pContext->m_pDevice->GetDeviceClass() != FXDC_DISPLAY; |   897     FX_BOOL bPrinting = pContext->m_pDevice->GetDeviceClass() != FXDC_DISPLAY; | 
|   898     pContext->m_pAnnots->DisplayAnnots(pPage, pContext->m_pContext.get(), |   898     pContext->m_pAnnots->DisplayAnnots(pPage, pContext->m_pContext.get(), | 
|   899                                        bPrinting, &matrix, TRUE, nullptr); |   899                                        bPrinting, &matrix, FALSE, nullptr); | 
|   900   } |   900   } | 
|   901  |   901  | 
|   902   pContext->m_pRenderer.reset(new CPDF_ProgressiveRenderer( |   902   pContext->m_pRenderer.reset(new CPDF_ProgressiveRenderer( | 
|   903       pContext->m_pContext.get(), pContext->m_pDevice.get(), |   903       pContext->m_pContext.get(), pContext->m_pDevice.get(), | 
|   904       pContext->m_pOptions.get())); |   904       pContext->m_pOptions.get())); | 
|   905   pContext->m_pRenderer->Start(pause); |   905   pContext->m_pRenderer->Start(pause); | 
|   906   if (bNeedToRestore) |   906   if (bNeedToRestore) | 
|   907     pContext->m_pDevice->RestoreState(false); |   907     pContext->m_pDevice->RestoreState(false); | 
|   908 } |   908 } | 
|   909  |   909  | 
| (...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  1128   if (!buffer) { |  1128   if (!buffer) { | 
|  1129     *buflen = len; |  1129     *buflen = len; | 
|  1130   } else if (*buflen >= len) { |  1130   } else if (*buflen >= len) { | 
|  1131     memcpy(buffer, utf16Name.c_str(), len); |  1131     memcpy(buffer, utf16Name.c_str(), len); | 
|  1132     *buflen = len; |  1132     *buflen = len; | 
|  1133   } else { |  1133   } else { | 
|  1134     *buflen = -1; |  1134     *buflen = -1; | 
|  1135   } |  1135   } | 
|  1136   return (FPDF_DEST)pDestObj; |  1136   return (FPDF_DEST)pDestObj; | 
|  1137 } |  1137 } | 
| OLD | NEW |