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

Unified Diff: components/pdf/browser/pdf_tab_helper_delegate.h

Issue 477263003: pdf: Create a separate component for using the pdf pepper plugin. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix-gn Created 6 years, 4 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_tab_helper_delegate.h
diff --git a/components/pdf/browser/pdf_tab_helper_delegate.h b/components/pdf/browser/pdf_tab_helper_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..45637a4fc600bb639d22710d7ea4e41147352d9d
--- /dev/null
+++ b/components/pdf/browser/pdf_tab_helper_delegate.h
@@ -0,0 +1,43 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef COMPONENTS_PDF_BROWSER_PDF_TAB_HELPER_DELEGATE_H_
+#define COMPONENTS_PDF_BROWSER_PDF_TAB_HELPER_DELEGATE_H_
+
+#include "base/callback.h"
+#include "base/strings/string16.h"
+#include "ipc/ipc_message.h"
+
+namespace content {
+class WebContents;
+}
+
+namespace pdf {
+
+typedef base::Callback<
+ void(bool /* success */, const base::string16& /* password */)>
+ PasswordDialogClosedCallback;
+
+class PDFTabHelperDelegate {
+ public:
+ virtual ~PDFTabHelperDelegate() {}
+
+ virtual void UpdateLocationBar(content::WebContents* contents) = 0;
+
+ virtual void UpdateContentRestrictions(content::WebContents* contents,
+ int content_restrictions) = 0;
+
+ virtual void OnPDFHasUnsupportedFeature(content::WebContents* contents) = 0;
+
+ virtual void OnSaveURL(content::WebContents* contents) = 0;
+
+ virtual void OnShowPDFPasswordDialog(
+ content::WebContents* contents,
+ const base::string16& prompt,
+ const PasswordDialogClosedCallback& callback) = 0;
+};
+
+} // namespace pdf
+
+#endif // COMPONENTS_PDF_BROWSER_PDF_TAB_HELPER_DELEGATE_H_

Powered by Google App Engine
This is Rietveld 408576698