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

Unified Diff: components/pdf/browser/pdf_web_contents_helper.cc

Issue 2672463003: Remove dead code since PDFWebContentsHelper::ShowOpenInReaderPrompt isn't called anymore. (Closed)
Patch Set: Created 3 years, 11 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
Index: components/pdf/browser/pdf_web_contents_helper.cc
diff --git a/components/pdf/browser/pdf_web_contents_helper.cc b/components/pdf/browser/pdf_web_contents_helper.cc
index ae931d4eae78087c42e5789eb558fd1159f0f436..e425338678771061207216a310fe8f6df4a5dc43 100644
--- a/components/pdf/browser/pdf_web_contents_helper.cc
+++ b/components/pdf/browser/pdf_web_contents_helper.cc
@@ -8,10 +8,8 @@
#include "base/bind.h"
#include "base/strings/utf_string_conversions.h"
-#include "components/pdf/browser/open_pdf_in_reader_prompt_client.h"
#include "components/pdf/browser/pdf_web_contents_helper_client.h"
#include "components/pdf/common/pdf_messages.h"
-#include "content/public/browser/navigation_details.h"
DEFINE_WEB_CONTENTS_USER_DATA_KEY(pdf::PDFWebContentsHelper);
@@ -35,12 +33,6 @@ PDFWebContentsHelper::PDFWebContentsHelper(
PDFWebContentsHelper::~PDFWebContentsHelper() {
}
-void PDFWebContentsHelper::ShowOpenInReaderPrompt(
- std::unique_ptr<OpenPDFInReaderPromptClient> prompt) {
- open_in_reader_prompt_ = std::move(prompt);
- UpdateLocationBar();
-}
-
bool PDFWebContentsHelper::OnMessageReceived(
const IPC::Message& message,
content::RenderFrameHost* render_frame_host) {
@@ -56,20 +48,6 @@ bool PDFWebContentsHelper::OnMessageReceived(
return handled;
}
-void PDFWebContentsHelper::DidNavigateMainFrame(
- const content::LoadCommittedDetails& details,
- const content::FrameNavigateParams& params) {
- if (open_in_reader_prompt_.get() &&
- open_in_reader_prompt_->ShouldExpire(details)) {
- open_in_reader_prompt_.reset();
- UpdateLocationBar();
- }
-}
-
-void PDFWebContentsHelper::UpdateLocationBar() {
- client_->UpdateLocationBar(web_contents());
-}
-
void PDFWebContentsHelper::OnHasUnsupportedFeature() {
client_->OnPDFHasUnsupportedFeature(web_contents());
}
« no previous file with comments | « components/pdf/browser/pdf_web_contents_helper.h ('k') | components/pdf/browser/pdf_web_contents_helper_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698