| 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 "xfa/fxfa/app/xfa_ffwidgetacc.h" | 7 #include "xfa/fxfa/app/xfa_ffwidgetacc.h" |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 1499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1510 if (pData->m_pDIBitmap && !pData->m_bNamedImage) | 1510 if (pData->m_pDIBitmap && !pData->m_bNamedImage) |
| 1511 delete pData->m_pDIBitmap; | 1511 delete pData->m_pDIBitmap; |
| 1512 | 1512 |
| 1513 pData->m_pDIBitmap = newImage; | 1513 pData->m_pDIBitmap = newImage; |
| 1514 } | 1514 } |
| 1515 | 1515 |
| 1516 CXFA_WidgetLayoutData* CXFA_WidgetAcc::GetWidgetLayoutData() { | 1516 CXFA_WidgetLayoutData* CXFA_WidgetAcc::GetWidgetLayoutData() { |
| 1517 return m_pLayoutData.get(); | 1517 return m_pLayoutData.get(); |
| 1518 } | 1518 } |
| 1519 | 1519 |
| 1520 IFGAS_Font* CXFA_WidgetAcc::GetFDEFont() { | 1520 CFGAS_GEFont* CXFA_WidgetAcc::GetFDEFont() { |
| 1521 CFX_WideStringC wsFontName = FX_WSTRC(L"Courier"); | 1521 CFX_WideStringC wsFontName = FX_WSTRC(L"Courier"); |
| 1522 uint32_t dwFontStyle = 0; | 1522 uint32_t dwFontStyle = 0; |
| 1523 if (CXFA_Font font = GetFont()) { | 1523 if (CXFA_Font font = GetFont()) { |
| 1524 if (font.IsBold()) { | 1524 if (font.IsBold()) { |
| 1525 dwFontStyle |= FX_FONTSTYLE_Bold; | 1525 dwFontStyle |= FX_FONTSTYLE_Bold; |
| 1526 } | 1526 } |
| 1527 if (font.IsItalic()) { | 1527 if (font.IsItalic()) { |
| 1528 dwFontStyle |= FX_FONTSTYLE_Italic; | 1528 dwFontStyle |= FX_FONTSTYLE_Italic; |
| 1529 } | 1529 } |
| 1530 font.GetTypeface(wsFontName); | 1530 font.GetTypeface(wsFontName); |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1690 if (pIDNode) { | 1690 if (pIDNode) { |
| 1691 pEmbAcc = (CXFA_WidgetAcc*)pIDNode->GetWidgetData(); | 1691 pEmbAcc = (CXFA_WidgetAcc*)pIDNode->GetWidgetData(); |
| 1692 } | 1692 } |
| 1693 if (pEmbAcc) { | 1693 if (pEmbAcc) { |
| 1694 pEmbAcc->GetValue(wsValue, XFA_VALUEPICTURE_Display); | 1694 pEmbAcc->GetValue(wsValue, XFA_VALUEPICTURE_Display); |
| 1695 return TRUE; | 1695 return TRUE; |
| 1696 } | 1696 } |
| 1697 } | 1697 } |
| 1698 return FALSE; | 1698 return FALSE; |
| 1699 } | 1699 } |
| OLD | NEW |