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

Side by Side Diff: printing/print_settings.cc

Issue 9415039: Add base::StaticAtomicSequenceNumber. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Update Created 8 years, 9 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
« no previous file with comments | « media/base/media_log.cc ('k') | webkit/quota/mock_storage_client.cc » ('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) 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 #include "printing/print_settings.h" 5 #include "printing/print_settings.h"
6 6
7 #include "base/atomic_sequence_num.h" 7 #include "base/atomic_sequence_num.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "printing/print_job_constants.h" 9 #include "printing/print_job_constants.h"
10 #include "printing/units.h" 10 #include "printing/units.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 bool isColorModelSelected(int model) { 101 bool isColorModelSelected(int model) {
102 return (model != GRAY && 102 return (model != GRAY &&
103 model != BLACK && 103 model != BLACK &&
104 model != PRINTOUTMODE_NORMAL_GRAY && 104 model != PRINTOUTMODE_NORMAL_GRAY &&
105 model != COLORMODE_MONOCHROME && 105 model != COLORMODE_MONOCHROME &&
106 model != PROCESSCOLORMODEL_GREYSCALE && 106 model != PROCESSCOLORMODEL_GREYSCALE &&
107 model != HP_COLOR_BLACK); 107 model != HP_COLOR_BLACK);
108 } 108 }
109 109
110 // Global SequenceNumber used for generating unique cookie values. 110 // Global SequenceNumber used for generating unique cookie values.
111 static base::AtomicSequenceNumber cookie_seq(base::LINKER_INITIALIZED); 111 static base::StaticAtomicSequenceNumber cookie_seq;
112 112
113 PrintSettings::PrintSettings() 113 PrintSettings::PrintSettings()
114 : min_shrink(1.25), 114 : min_shrink(1.25),
115 max_shrink(2.0), 115 max_shrink(2.0),
116 desired_dpi(72), 116 desired_dpi(72),
117 selection_only(false), 117 selection_only(false),
118 margin_type(DEFAULT_MARGINS), 118 margin_type(DEFAULT_MARGINS),
119 display_header_footer(false), 119 display_header_footer(false),
120 dpi_(0), 120 dpi_(0),
121 landscape_(false), 121 landscape_(false),
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 } 240 }
241 241
242 void PrintSettings::SetOrientation(bool landscape) { 242 void PrintSettings::SetOrientation(bool landscape) {
243 if (landscape_ != landscape) { 243 if (landscape_ != landscape) {
244 landscape_ = landscape; 244 landscape_ = landscape;
245 page_setup_device_units_.FlipOrientation(); 245 page_setup_device_units_.FlipOrientation();
246 } 246 }
247 } 247 }
248 248
249 } // namespace printing 249 } // namespace printing
OLDNEW
« no previous file with comments | « media/base/media_log.cc ('k') | webkit/quota/mock_storage_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698