From 68eefa6a6f6bbab73000a29e2cac3e104be1cc81 Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Wed, 30 Aug 2017 12:16:16 -0400 Subject: Rebuild CFDE_TextEditEngine. This CL rebuilds the text edit engine in a simpler fashion. Instead of depending on multiple pages, paragraphs and buffer fields there is a single text edit engine which contains a gap buffer. This makes the code easier to understand and follow. Change-Id: I10fe85603fa9ed15a647eaac2d931f113cd0c7b0 Reviewed-on: https://pdfium-review.googlesource.com/11990 Commit-Queue: dsinclair Reviewed-by: Henrique Nakashima Reviewed-by: Ryan Harrison --- xfa/fwl/cfwl_comboedit.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'xfa/fwl/cfwl_comboedit.cpp') diff --git a/xfa/fwl/cfwl_comboedit.cpp b/xfa/fwl/cfwl_comboedit.cpp index 68cde76707..2e53dbdf80 100644 --- a/xfa/fwl/cfwl_comboedit.cpp +++ b/xfa/fwl/cfwl_comboedit.cpp @@ -9,7 +9,7 @@ #include #include -#include "xfa/fde/cfde_txtedtengine.h" +#include "xfa/fde/cfde_texteditengine.h" #include "xfa/fwl/cfwl_combobox.h" #include "xfa/fwl/cfwl_messagemouse.h" @@ -22,14 +22,16 @@ CFWL_ComboEdit::CFWL_ComboEdit( } void CFWL_ComboEdit::ClearSelected() { - ClearSelections(); + ClearSelection(); RepaintRect(GetRTClient()); } void CFWL_ComboEdit::SetSelected() { FlagFocus(true); - GetTxtEdtEngine()->MoveCaretPos(FDE_CaretMove::End, false); - AddSelRange(0); + + // TODO(dsinclair): Fix CFWL_CombEdit::SetSelected + // GetTxtEdtEngine()->MoveCaretPos(FDE_CaretMove::End, false); + SelectAll(); } void CFWL_ComboEdit::FlagFocus(bool bSet) { -- cgit v1.2.3