diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2017-08-30 12:16:16 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-08-30 16:26:12 +0000 |
commit | 68eefa6a6f6bbab73000a29e2cac3e104be1cc81 (patch) | |
tree | b48dbf0932022bc551ae06e2400262c203856942 /xfa/fwl/cfwl_combobox.h | |
parent | aa3a9cd82df9dff1ef136797259e606a39c18b75 (diff) | |
download | pdfium-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_combobox.h')
-rw-r--r-- | xfa/fwl/cfwl_combobox.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/xfa/fwl/cfwl_combobox.h b/xfa/fwl/cfwl_combobox.h index 0e1f815872..7242b1f450 100644 --- a/xfa/fwl/cfwl_combobox.h +++ b/xfa/fwl/cfwl_combobox.h @@ -76,7 +76,7 @@ class CFWL_ComboBox : public CFWL_Widget { bool EditCanRedo() const { return m_pEdit->CanRedo(); } bool EditUndo() { return m_pEdit->Undo(); } bool EditRedo() { return m_pEdit->Redo(); } - bool EditCanCopy() const { return m_pEdit->CountSelRanges() > 0; } + bool EditCanCopy() const { return m_pEdit->HasSelection(); } bool EditCanCut() const { if (m_pEdit->GetStylesEx() & FWL_STYLEEXT_EDT_ReadOnly) return false; @@ -88,9 +88,9 @@ class CFWL_ComboBox : public CFWL_Widget { bool EditPaste(const CFX_WideString& wsPaste) { return m_pEdit->Paste(wsPaste); } - void EditSelectAll() { m_pEdit->AddSelRange(0); } + void EditSelectAll() { m_pEdit->SelectAll(); } void EditDelete() { m_pEdit->ClearText(); } - void EditDeSelect() { m_pEdit->ClearSelections(); } + void EditDeSelect() { m_pEdit->ClearSelection(); } CFX_RectF GetBBox() const; void EditModifyStylesEx(uint32_t dwStylesExAdded, uint32_t dwStylesExRemoved); |