summaryrefslogtreecommitdiffstats
path: root/chrome/service/service_utility_process_host.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/service/service_utility_process_host.cc')
-rw-r--r--chrome/service/service_utility_process_host.cc14
1 files changed, 5 insertions, 9 deletions
diff --git a/chrome/service/service_utility_process_host.cc b/chrome/service/service_utility_process_host.cc
index a340d8d..b63e27f 100644
--- a/chrome/service/service_utility_process_host.cc
+++ b/chrome/service/service_utility_process_host.cc
@@ -13,15 +13,13 @@
#include "chrome/common/chrome_switches.h"
#include "chrome/common/utility_messages.h"
#include "ipc/ipc_switches.h"
+#include "printing/native_metafile.h"
#include "printing/page_range.h"
#include "ui/base/ui_base_switches.h"
#include "ui/gfx/rect.h"
#if defined(OS_WIN)
-#include "base/scoped_ptr.h"
#include "base/win/scoped_handle.h"
-#include "printing/native_metafile_factory.h"
-#include "printing/native_metafile.h"
#endif
ServiceUtilityProcessHost::ServiceUtilityProcessHost(
@@ -204,15 +202,13 @@ void ServiceUtilityProcessHost::Client::MetafileAvailable(
if (!scratch_metafile_dir.Set(metafile_path.DirName()))
LOG(WARNING) << "Unable to set scratch metafile directory";
#if defined(OS_WIN)
- scoped_ptr<printing::NativeMetafile> metafile(
- printing::NativeMetafileFactory::CreateMetafile());
- if (!metafile->CreateFromFile(metafile_path)) {
+ printing::NativeMetafile metafile;
+ if (!metafile.CreateFromFile(metafile_path)) {
OnRenderPDFPagesToMetafileFailed();
} else {
- OnRenderPDFPagesToMetafileSucceeded(*metafile,
- highest_rendered_page_number);
+ OnRenderPDFPagesToMetafileSucceeded(metafile, highest_rendered_page_number);
// Close it so that ScopedTempDir can delete the folder.
- metafile->CloseEmf();
+ metafile.CloseEmf();
}
#endif // defined(OS_WIN)
}