Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1874)

Unified Diff: pdf/pdfium/pdfium_engine.h

Issue 2963753003: Fix discrepancies in form text selection between PDF and HTML forms. (Closed)
Patch Set: Adjust calls to SetMouseLeftButtonDown() to avoid early returns Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | pdf/pdfium/pdfium_engine.cc » ('j') | pdf/pdfium/pdfium_engine.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pdf/pdfium/pdfium_engine.h
diff --git a/pdf/pdfium/pdfium_engine.h b/pdf/pdfium/pdfium_engine.h
index 5b46fc06689c0cf185135bc0ae42a0f048a12d27..e19570d0be9677d40f952f738725507cd7922fc9 100644
--- a/pdf/pdfium/pdfium_engine.h
+++ b/pdf/pdfium/pdfium_engine.h
@@ -453,6 +453,9 @@ class PDFiumEngine : public PDFEngine,
// field.
void SetInFormTextArea(bool in_form_text_area);
+ // Sets whether or not left mouse button is currently being held down.
+ void SetMouseLeftButtonDown(bool is_mouse_left_button_down);
+
bool PageIndexInBounds(int index) const;
void ScheduleTouchTimer(const pp::TouchInputEvent& event);
@@ -653,16 +656,22 @@ class PDFiumEngine : public PDFEngine,
bool defer_page_unload_;
std::vector<int> deferred_page_unloads_;
- // Used for text selection, but does not include text within form text fields.
+ // Used for text selection, but does not include text within form text areas.
// There could be more than one range if selection spans more than one page.
std::vector<PDFiumRange> selection_;
// True if we're in the middle of text selection.
bool selecting_;
+ MouseDownState mouse_down_state_;
+
+ // Text selection within form text fields and form combobox text fields.
+ std::string selected_form_text_;
+
// True if focus is in form text field or form combobox text field.
bool in_form_text_area_;
- MouseDownState mouse_down_state_;
+ // True if left mouse button is currently being held down.
+ bool mouse_left_button_down_;
Lei Zhang 2017/07/05 22:02:21 We need to initialize this. We also forgot to init
drgage 2017/07/06 19:13:55 Done.
// Used for searching.
std::vector<PDFiumRange> find_results_;
« no previous file with comments | « no previous file | pdf/pdfium/pdfium_engine.cc » ('j') | pdf/pdfium/pdfium_engine.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698