diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-02 17:20:21 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-02 17:20:21 +0000 |
commit | 7756e5b1e7919fe530ff1ff27503d4893efcee13 (patch) | |
tree | 5b7ac359e22bf58e5ae72fbdc57a6b6c92efe285 /printing/native_metafile.h | |
parent | f3e9d6e12d38ea05e476899eb2620c57d351f74b (diff) | |
download | chromium_src-7756e5b1e7919fe530ff1ff27503d4893efcee13.zip chromium_src-7756e5b1e7919fe530ff1ff27503d4893efcee13.tar.gz chromium_src-7756e5b1e7919fe530ff1ff27503d4893efcee13.tar.bz2 |
Revert 76553 - Applying factory pattern (through NativeMetafileFactory class). It is used to retrieve different printing contexts (based on the platform and user preferences).
BUG=NONE
TEST=NONE
Review URL: http://codereview.chromium.org/6544028
TBR=dpapad@chromium.org
Review URL: http://codereview.chromium.org/6594121
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76555 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'printing/native_metafile.h')
-rw-r--r-- | printing/native_metafile.h | 41 |
1 files changed, 36 insertions, 5 deletions
diff --git a/printing/native_metafile.h b/printing/native_metafile.h index 7e1d25b..b0f957a 100644 --- a/printing/native_metafile.h +++ b/printing/native_metafile.h @@ -1,19 +1,50 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2009 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 PRINTING_NATIVE_METAFILE_H_ #define PRINTING_NATIVE_METAFILE_H_ -#include "base/basictypes.h" #include "build/build_config.h" +// Define a metafile format for the current platform. We use this platform +// independent define so we can define interfaces in platform agnostic manner. +// It is still an outstanding design issue whether we create classes on all +// platforms that have the same interface as Emf or if we change Emf to support +// multiple platforms (and rename to NativeMetafile). + + #if defined(OS_WIN) -#include "printing/native_metafile_win.h" + +#include "printing/emf_win.h" + +namespace printing { + +typedef Emf NativeMetafile; + +} // namespace printing + #elif defined(OS_MACOSX) -#include "printing/native_metafile_mac.h" + +#include "printing/pdf_metafile_mac.h" + +namespace printing { + +typedef PdfMetafile NativeMetafile; + +} // namespace printing + #elif defined(OS_POSIX) -#include "printing/native_metafile_linux.h" + +#include "printing/pdf_ps_metafile_cairo.h" + +namespace printing { + +typedef PdfPsMetafile NativeMetafile; + +} // namespace printing + #endif + #endif // PRINTING_NATIVE_METAFILE_H_ |