diff options
author | Tom Sepez <tsepez@chromium.org> | 2016-02-17 10:07:21 -0800 |
---|---|---|
committer | Tom Sepez <tsepez@chromium.org> | 2016-02-17 10:07:21 -0800 |
commit | ab27768d235985c0789a10ab490be43e262f48f6 (patch) | |
tree | 692c2707020bee87753c05208c7d0c6f176ff30b /xfa/src/fwl | |
parent | 32c70815316672091946be88e5941089c359d151 (diff) | |
download | pdfium-ab27768d235985c0789a10ab490be43e262f48f6.tar.xz |
Banish CFX_ByteArray and CFX_WideArray to the XFA side.
Fix IWYU and include paths as we go.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1701883004 .
Diffstat (limited to 'xfa/src/fwl')
-rw-r--r-- | xfa/src/fwl/src/basewidget/fwl_editimp.cpp | 4 | ||||
-rw-r--r-- | xfa/src/fwl/src/basewidget/include/fwl_editimp.h | 17 | ||||
-rw-r--r-- | xfa/src/fwl/src/lightwidget/edit.cpp | 2 |
3 files changed, 15 insertions, 8 deletions
diff --git a/xfa/src/fwl/src/basewidget/fwl_editimp.cpp b/xfa/src/fwl/src/basewidget/fwl_editimp.cpp index f5342d0f52..263968652b 100644 --- a/xfa/src/fwl/src/basewidget/fwl_editimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_editimp.cpp @@ -155,7 +155,7 @@ void IFWL_Edit::SetScrollOffset(FX_FLOAT fScrollOffset) { return static_cast<CFWL_EditImp*>(GetImpl())->SetScrollOffset(fScrollOffset); } FX_BOOL IFWL_Edit::GetSuggestWords(CFX_PointF pointf, - CFX_ByteStringArray& sSuggest) { + std::vector<CFX_ByteString>& sSuggest) { return static_cast<CFWL_EditImp*>(GetImpl()) ->GetSuggestWords(pointf, sSuggest); } @@ -357,7 +357,7 @@ int32_t CFWL_EditImp::GetWordAtPoint(CFX_PointF pointf, int32_t& nCount) { return 0; } FX_BOOL CFWL_EditImp::GetSuggestWords(CFX_PointF pointf, - CFX_ByteStringArray& sSuggest) { + std::vector<CFX_ByteString>& sSuggest) { int32_t nWordCount = 0; int32_t nWordStart = GetWordAtPoint(pointf, nWordCount); if (nWordCount < 1) { diff --git a/xfa/src/fwl/src/basewidget/include/fwl_editimp.h b/xfa/src/fwl/src/basewidget/include/fwl_editimp.h index 67e6b69adb..d7e736106e 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_editimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_editimp.h @@ -4,12 +4,15 @@ // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com -#ifndef _FWL_EDIT_IMP_H -#define _FWL_EDIT_IMP_H +#ifndef FWL_EDITIMP_H_ +#define FWL_EDITIMP_H_ #include <memory> +#include <vector> + +#include "xfa/src/fee/include/ifde_txtedtengine.h" +#include "xfa/src/fwl/src/core/include/fwl_widgetimp.h" -class CFWL_WidgetImp; class CFWL_WidgetImpProperties; class CFWL_WidgetImpDelegate; class CFWL_ScrollBarImp; @@ -17,6 +20,7 @@ class IFWL_Caret; class IFWL_AdapterTextField; class CFWL_EditImp; class CFWL_EditImpDelegate; + class CFWL_EditImp : public CFWL_WidgetImp, public IFDE_TxtEdtEventSink { public: CFWL_EditImp(const CFWL_WidgetImpProperties& properties, IFWL_Widget* pOuter); @@ -106,7 +110,8 @@ class CFWL_EditImp : public CFWL_WidgetImp, public IFDE_TxtEdtEventSink { virtual FWL_ERR SetBackgroundColor(FX_DWORD color); virtual FWL_ERR SetFont(const CFX_WideString& wsFont, FX_FLOAT fSize); void SetScrollOffset(FX_FLOAT fScrollOffset); - FX_BOOL GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray& sSuggest); + FX_BOOL GetSuggestWords(CFX_PointF pointf, + std::vector<CFX_ByteString>& sSuggest); FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, const CFX_ByteStringC& bsReplace); @@ -177,6 +182,7 @@ class CFWL_EditImp : public CFWL_WidgetImp, public IFDE_TxtEdtEventSink { int32_t m_iCurRecord; int32_t m_iMaxRecord; }; + class CFWL_EditImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_EditImpDelegate(CFWL_EditImp* pOwner); @@ -200,4 +206,5 @@ class CFWL_EditImpDelegate : public CFWL_WidgetImpDelegate { void DoCursor(CFWL_MsgMouse* pMsg); CFWL_EditImp* m_pOwner; }; -#endif + +#endif // FWL_EDITIMP_H_ diff --git a/xfa/src/fwl/src/lightwidget/edit.cpp b/xfa/src/fwl/src/lightwidget/edit.cpp index 0d207ee288..f7667cb3a9 100644 --- a/xfa/src/fwl/src/lightwidget/edit.cpp +++ b/xfa/src/fwl/src/lightwidget/edit.cpp @@ -201,7 +201,7 @@ void CFWL_Edit::SetScrollOffset(FX_FLOAT fScrollOffset) { return static_cast<IFWL_Edit*>(m_pIface)->SetScrollOffset(fScrollOffset); } FX_BOOL CFWL_Edit::GetSuggestWords(CFX_PointF pointf, - CFX_ByteStringArray& sSuggest) { + std::vector<CFX_ByteString>& sSuggest) { return static_cast<IFWL_Edit*>(m_pIface)->GetSuggestWords(pointf, sSuggest); } FX_BOOL CFWL_Edit::ReplaceSpellCheckWord(CFX_PointF pointf, |