1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef ANDROID_WEBVIEW_NATIVE_AW_PDF_EXPORTER_H_
6 #define ANDROID_WEBVIEW_NATIVE_AW_PDF_EXPORTER_H_
10 #include "base/android/jni_weak_ref.h"
11 #include "base/android/scoped_java_ref.h"
12 #include "base/basictypes.h"
13 #include "skia/ext/refptr.h"
23 namespace android_webview
{
27 AwPdfExporter(JNIEnv
* env
,
29 content::WebContents
* web_contents
);
33 void ExportToPdf(JNIEnv
* env
,
36 jobject cancel_signal
);
39 void InitPdfSettings(JNIEnv
* env
,
41 printing::PrintSettings
& settings
);
42 void DidExportPdf(int fd
, bool success
);
44 JavaObjectWeakGlobalRef java_ref_
;
45 content::WebContents
* web_contents_
;
47 DISALLOW_COPY_AND_ASSIGN(AwPdfExporter
);
50 bool RegisterAwPdfExporter(JNIEnv
* env
);
52 } // namespace android_webview
54 #endif // ANDROID_WEBVIEW_NATIVE_AW_PDF_EXPORTER_H_