mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Add support for printing via CefBrowserHost::Print() and JavaScript window.print() (issue #505).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1479 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@@ -26,6 +26,10 @@
|
||||
#include "ui/base/resource/resource_bundle.h"
|
||||
#include "v8/include/v8.h"
|
||||
|
||||
#if defined(OS_LINUX)
|
||||
#include "chrome/browser/printing/print_dialog_gtk.h"
|
||||
#endif
|
||||
|
||||
CefBrowserMainParts::CefBrowserMainParts(
|
||||
const content::MainFunctionParams& parameters)
|
||||
: BrowserMainParts(),
|
||||
@@ -48,6 +52,11 @@ void CefBrowserMainParts::PostMainMessageLoopStart() {
|
||||
// CEF's internal handling of "chrome://tracing".
|
||||
content::WebUIControllerFactory::UnregisterFactoryForTesting(
|
||||
content::ContentWebUIControllerFactory::GetInstance());
|
||||
|
||||
#if defined(OS_LINUX)
|
||||
printing::PrintingContextGtk::SetCreatePrintDialogFunction(
|
||||
&PrintDialogGtk::CreatePrintDialog);
|
||||
#endif
|
||||
}
|
||||
|
||||
int CefBrowserMainParts::PreCreateThreads() {
|
||||
|
Reference in New Issue
Block a user