Index: pdf/pdfium/pdfium_engine.cc |
diff --git a/pdf/pdfium/pdfium_engine.cc b/pdf/pdfium/pdfium_engine.cc |
index 228a8899cc4f5436c1ca4b7f7015ce40e68d05da..ca682572dfd85185818641ba961728e2fbbf88f5 100644 |
--- a/pdf/pdfium/pdfium_engine.cc |
+++ b/pdf/pdfium/pdfium_engine.cc |
@@ -1683,7 +1683,7 @@ bool PDFiumEngine::OnMouseDown(const pp::MouseInputEvent& event) { |
} |
void PDFiumEngine::OnSingleClick(int page_index, int char_index) { |
- selecting_ = true; |
+ SetSelecting(true); |
selection_.push_back(PDFiumRange(pages_[page_index], char_index, 0)); |
} |
@@ -1746,7 +1746,7 @@ bool PDFiumEngine::OnMouseUp(const pp::MouseInputEvent& event) { |
if (!selecting_) |
return false; |
- selecting_ = false; |
+ SetSelecting(false); |
return true; |
} |
@@ -3368,6 +3368,13 @@ void PDFiumEngine::RotateInternal() { |
} |
} |
+void PDFiumEngine::SetSelecting(bool selecting) { |
+ bool was_selecting = selecting_; |
+ selecting_ = selecting; |
+ if (selecting_ != was_selecting) |
+ engine->client_->IsSelectingChanged(selecting); |
+} |
+ |
void PDFiumEngine::Form_Invalidate(FPDF_FORMFILLINFO* param, |
FPDF_PAGE page, |
double left, |