Index: pdf/pdfium/pdfium_engine.h |
diff --git a/pdf/pdfium/pdfium_engine.h b/pdf/pdfium/pdfium_engine.h |
index 6620c77cb6bad9313550bdb79835ac494e61afdb..2a0aba6305d61cc785a5384f24ed86cfdfd53a91 100644 |
--- a/pdf/pdfium/pdfium_engine.h |
+++ b/pdf/pdfium/pdfium_engine.h |
@@ -318,6 +318,10 @@ class PDFiumEngine : public PDFEngine, |
const PP_PrintSettings_Dev& print_settings); |
void SaveSelectedFormForPrint(); |
+ // Sets plugin's selected text to be selected text in form text field |
Lei Zhang
2017/06/20 00:26:24
I don't know why I didn't notice earlier. What doe
Lei Zhang
2017/06/20 18:34:57
How about this?
Checks if |page| has selected tex
drgage
2017/06/20 23:14:27
Done.
drgage
2017/06/20 23:14:27
What I meant by available is if selected text in a
|
+ // or form combobox text field if available. |
+ void SetFormSelectedText(FPDF_FORMHANDLE form_handle, FPDF_PAGE page); |
+ |
// Given a mouse event, returns which page and character location it's closest |
// to. |
PDFiumPage::Area GetCharIndex(const pp::MouseInputEvent& event, |
@@ -437,9 +441,14 @@ class PDFiumEngine : public PDFEngine, |
// Common code shared by RotateClockwise() and RotateCounterclockwise(). |
void RotateInternal(); |
- // Setting selection status of document. |
+ // Setting text selection status of document. This does not include text |
Lei Zhang
2017/06/20 18:34:58
Let's use "Sets ..." here for consistency.
drgage
2017/06/20 23:14:27
Done.
|
+ // within form text fields. |
void SetSelecting(bool selecting); |
+ // Sets status of whether or not focus is in form text field or form combobox |
Lei Zhang
2017/06/20 00:26:24
You can probably omit "status of" here.
drgage
2017/06/20 23:14:27
Done.
|
+ // text field. |
+ void SetInFormTextArea(bool in_form_text_area); |
+ |
bool PageIndexInBounds(int index) const; |
void ScheduleTouchTimer(const pp::TouchInputEvent& event); |
@@ -640,12 +649,15 @@ class PDFiumEngine : public PDFEngine, |
bool defer_page_unload_; |
std::vector<int> deferred_page_unloads_; |
- // Used for selection. There could be more than one range if selection spans |
- // more than one page. |
+ // Used for text selection, but does not include text within form text fields. |
+ // 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 selection. |
+ // True if we're in the middle of text selection. |
bool selecting_; |
+ // True if focus is on form text field or form combobox text field. |
Lei Zhang
2017/06/20 00:26:24
Line 448 says "focus is in". Be consistent?
drgage
2017/06/20 23:14:27
Done.
|
+ bool in_form_text_area_; |
+ |
MouseDownState mouse_down_state_; |
// Used for searching. |