| 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/include/fwl/lightwidget/edit.h" | 7 #include "xfa/include/fwl/lightwidget/edit.h" |
| 8 | 8 |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 154 return FWL_ERR_Indefinite; | 154 return FWL_ERR_Indefinite; |
| 155 return static_cast<IFWL_Edit*>(m_pIface) | 155 return static_cast<IFWL_Edit*>(m_pIface) |
| 156 ->SetTabWidth(fTabWidth, bEquidistant); | 156 ->SetTabWidth(fTabWidth, bEquidistant); |
| 157 } | 157 } |
| 158 FWL_ERR CFWL_Edit::SetNumberRange(int32_t iMin, int32_t iMax) { | 158 FWL_ERR CFWL_Edit::SetNumberRange(int32_t iMin, int32_t iMax) { |
| 159 if (iMin > iMax) { | 159 if (iMin > iMax) { |
| 160 return FWL_ERR_Parameter_Invalid; | 160 return FWL_ERR_Parameter_Invalid; |
| 161 } | 161 } |
| 162 return static_cast<IFWL_Edit*>(m_pIface)->SetNumberRange(iMin, iMax); | 162 return static_cast<IFWL_Edit*>(m_pIface)->SetNumberRange(iMin, iMax); |
| 163 } | 163 } |
| 164 FWL_ERR CFWL_Edit::SetBackColor(FX_DWORD dwColor) { | 164 FWL_ERR CFWL_Edit::SetBackColor(uint32_t dwColor) { |
| 165 if (!m_pIface) | 165 if (!m_pIface) |
| 166 return FWL_ERR_Indefinite; | 166 return FWL_ERR_Indefinite; |
| 167 return static_cast<IFWL_Edit*>(m_pIface)->SetBackColor(dwColor); | 167 return static_cast<IFWL_Edit*>(m_pIface)->SetBackColor(dwColor); |
| 168 } | 168 } |
| 169 FWL_ERR CFWL_Edit::SetFont(const CFX_WideString& wsFont, FX_FLOAT fSize) { | 169 FWL_ERR CFWL_Edit::SetFont(const CFX_WideString& wsFont, FX_FLOAT fSize) { |
| 170 if (!m_pIface) | 170 if (!m_pIface) |
| 171 return FWL_ERR_Indefinite; | 171 return FWL_ERR_Indefinite; |
| 172 return static_cast<IFWL_Edit*>(m_pIface)->SetFont(wsFont, fSize); | 172 return static_cast<IFWL_Edit*>(m_pIface)->SetFont(wsFont, fSize); |
| 173 } | 173 } |
| 174 FX_BOOL CFWL_Edit::CanUndo() { | 174 FX_BOOL CFWL_Edit::CanUndo() { |
| (...skipping 27 matching lines...) Expand all Loading... |
| 202 std::vector<CFX_ByteString>& sSuggest) { | 202 std::vector<CFX_ByteString>& sSuggest) { |
| 203 return static_cast<IFWL_Edit*>(m_pIface)->GetSuggestWords(pointf, sSuggest); | 203 return static_cast<IFWL_Edit*>(m_pIface)->GetSuggestWords(pointf, sSuggest); |
| 204 } | 204 } |
| 205 FX_BOOL CFWL_Edit::ReplaceSpellCheckWord(CFX_PointF pointf, | 205 FX_BOOL CFWL_Edit::ReplaceSpellCheckWord(CFX_PointF pointf, |
| 206 const CFX_ByteStringC& bsReplace) { | 206 const CFX_ByteStringC& bsReplace) { |
| 207 return static_cast<IFWL_Edit*>(m_pIface) | 207 return static_cast<IFWL_Edit*>(m_pIface) |
| 208 ->ReplaceSpellCheckWord(pointf, bsReplace); | 208 ->ReplaceSpellCheckWord(pointf, bsReplace); |
| 209 } | 209 } |
| 210 CFWL_Edit::CFWL_Edit() {} | 210 CFWL_Edit::CFWL_Edit() {} |
| 211 CFWL_Edit::~CFWL_Edit() {} | 211 CFWL_Edit::~CFWL_Edit() {} |
| OLD | NEW |