OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef PRINTING_PDF_METAFILE_SKIA_H_ | 5 #ifndef PRINTING_PDF_METAFILE_SKIA_H_ |
6 #define PRINTING_PDF_METAFILE_SKIA_H_ | 6 #define PRINTING_PDF_METAFILE_SKIA_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/scoped_ptr.h" | 10 #include "base/scoped_ptr.h" |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 bool shrink_to_fit, | 61 bool shrink_to_fit, |
62 bool stretch_to_fit, | 62 bool stretch_to_fit, |
63 bool center_horizontally, | 63 bool center_horizontally, |
64 bool center_vertically) const; | 64 bool center_vertically) const; |
65 #endif | 65 #endif |
66 | 66 |
67 #if defined(OS_CHROMEOS) | 67 #if defined(OS_CHROMEOS) |
68 virtual bool SaveToFD(const base::FileDescriptor& fd) const; | 68 virtual bool SaveToFD(const base::FileDescriptor& fd) const; |
69 #endif // if defined(OS_CHROMEOS) | 69 #endif // if defined(OS_CHROMEOS) |
70 | 70 |
| 71 // Return a new metafile containing just the current page in draft mode. |
| 72 PdfMetafileSkia* GetMetafileForCurrentPage(); |
| 73 |
71 private: | 74 private: |
72 scoped_ptr<PdfMetafileSkiaData> data_; | 75 scoped_ptr<PdfMetafileSkiaData> data_; |
73 | 76 |
74 // True when a draft version of metafile is requested. | 77 // True when a draft version of metafile is requested. |
75 mutable bool draft_; | 78 mutable bool draft_; |
76 | 79 |
| 80 // True when finish page is outstanding for current page. |
| 81 bool page_outstanding_; |
| 82 |
77 DISALLOW_COPY_AND_ASSIGN(PdfMetafileSkia); | 83 DISALLOW_COPY_AND_ASSIGN(PdfMetafileSkia); |
78 }; | 84 }; |
79 | 85 |
80 } // namespace printing | 86 } // namespace printing |
81 | 87 |
82 #endif // PRINTING_PDF_METAFILE_SKIA_H_ | 88 #endif // PRINTING_PDF_METAFILE_SKIA_H_ |
OLD | NEW |