Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(377)

Side by Side Diff: printing/printed_document.h

Issue 12163003: Add FilePath to base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « printing/pdf_metafile_skia.h ('k') | remoting/host/audio_capturer_linux.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_PRINTED_DOCUMENT_H_ 5 #ifndef PRINTING_PRINTED_DOCUMENT_H_
6 #define PRINTING_PRINTED_DOCUMENT_H_ 6 #define PRINTING_PRINTED_DOCUMENT_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "base/string16.h" 11 #include "base/string16.h"
12 #include "base/synchronization/lock.h" 12 #include "base/synchronization/lock.h"
13 #include "printing/print_settings.h" 13 #include "printing/print_settings.h"
14 #include "ui/gfx/native_widget_types.h" 14 #include "ui/gfx/native_widget_types.h"
15 15
16 class MessageLoop;
17
18 namespace base {
16 class FilePath; 19 class FilePath;
17 class MessageLoop; 20 }
18 21
19 namespace printing { 22 namespace printing {
20 23
21 class Metafile; 24 class Metafile;
22 class PrintedPage; 25 class PrintedPage;
23 class PrintedPagesSource; 26 class PrintedPagesSource;
24 class PrintingContext; 27 class PrintingContext;
25 28
26 // A collection of rendered pages. The settings are immutable. If the print 29 // A collection of rendered pages. The settings are immutable. If the print
27 // settings are changed, a new PrintedDocument must be created. 30 // settings are changed, a new PrintedDocument must be created.
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 // Note: locks for a short amount of time. 89 // Note: locks for a short amount of time.
87 int expected_page_count() const; 90 int expected_page_count() const;
88 91
89 // Getters. All these items are immutable hence thread-safe. 92 // Getters. All these items are immutable hence thread-safe.
90 const PrintSettings& settings() const { return immutable_.settings_; } 93 const PrintSettings& settings() const { return immutable_.settings_; }
91 const string16& name() const { return immutable_.name_; } 94 const string16& name() const { return immutable_.name_; }
92 int cookie() const { return immutable_.cookie_; } 95 int cookie() const { return immutable_.cookie_; }
93 96
94 // Sets a path where to dump printing output files for debugging. If never set 97 // Sets a path where to dump printing output files for debugging. If never set
95 // no files are generated. 98 // no files are generated.
96 static void set_debug_dump_path(const FilePath& debug_dump_path); 99 static void set_debug_dump_path(const base::FilePath& debug_dump_path);
97 100
98 static const FilePath& debug_dump_path(); 101 static const base::FilePath& debug_dump_path();
99 102
100 private: 103 private:
101 friend class base::RefCountedThreadSafe<PrintedDocument>; 104 friend class base::RefCountedThreadSafe<PrintedDocument>;
102 105
103 virtual ~PrintedDocument(); 106 virtual ~PrintedDocument();
104 107
105 // Array of data for each print previewed page. 108 // Array of data for each print previewed page.
106 typedef std::map<int, scoped_refptr<PrintedPage> > PrintedPages; 109 typedef std::map<int, scoped_refptr<PrintedPage> > PrintedPages;
107 110
108 // Contains all the mutable stuff. All this stuff MUST be accessed with the 111 // Contains all the mutable stuff. All this stuff MUST be accessed with the
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 172
170 // All the immutable members. 173 // All the immutable members.
171 const Immutable immutable_; 174 const Immutable immutable_;
172 175
173 DISALLOW_COPY_AND_ASSIGN(PrintedDocument); 176 DISALLOW_COPY_AND_ASSIGN(PrintedDocument);
174 }; 177 };
175 178
176 } // namespace printing 179 } // namespace printing
177 180
178 #endif // PRINTING_PRINTED_DOCUMENT_H_ 181 #endif // PRINTING_PRINTED_DOCUMENT_H_
OLDNEW
« no previous file with comments | « printing/pdf_metafile_skia.h ('k') | remoting/host/audio_capturer_linux.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698