summaryrefslogtreecommitdiff
path: root/xfa/fwl/cfwl_comboedit.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-08-30 12:16:16 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-08-30 16:26:12 +0000
commit68eefa6a6f6bbab73000a29e2cac3e104be1cc81 (patch)
treeb48dbf0932022bc551ae06e2400262c203856942 /xfa/fwl/cfwl_comboedit.cpp
parentaa3a9cd82df9dff1ef136797259e606a39c18b75 (diff)
downloadpdfium-68eefa6a6f6bbab73000a29e2cac3e104be1cc81.tar.xz
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 <dsinclair@chromium.org> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Diffstat (limited to 'xfa/fwl/cfwl_comboedit.cpp')
-rw-r--r--xfa/fwl/cfwl_comboedit.cpp10
1 files changed, 6 insertions, 4 deletions
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 <memory>
#include <utility>
-#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) {