| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 // TODO(jhawkins): Move platform-specific implementations to their own files. | 7 // TODO(jhawkins): Move platform-specific implementations to their own files. |
| 8 #if defined(USE_X11) | 8 #if defined(USE_X11) |
| 9 #include <gtk/gtk.h> | 9 #include <gtk/gtk.h> |
| 10 #endif // defined(USE_X11) | 10 #endif // defined(USE_X11) |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 PrintSettings::PrintSettings() | 24 PrintSettings::PrintSettings() |
| 25 : min_shrink(1.25), | 25 : min_shrink(1.25), |
| 26 max_shrink(2.0), | 26 max_shrink(2.0), |
| 27 desired_dpi(72), | 27 desired_dpi(72), |
| 28 selection_only(false), | 28 selection_only(false), |
| 29 use_overlays(true), | 29 use_overlays(true), |
| 30 dpi_(0), | 30 dpi_(0), |
| 31 landscape_(false) { | 31 landscape_(false) { |
| 32 } | 32 } |
| 33 | 33 |
| 34 PrintSettings::~PrintSettings() { |
| 35 } |
| 36 |
| 34 void PrintSettings::Clear() { | 37 void PrintSettings::Clear() { |
| 35 ranges.clear(); | 38 ranges.clear(); |
| 36 min_shrink = 1.25; | 39 min_shrink = 1.25; |
| 37 max_shrink = 2.; | 40 max_shrink = 2.; |
| 38 desired_dpi = 72; | 41 desired_dpi = 72; |
| 39 selection_only = false; | 42 selection_only = false; |
| 40 printer_name_.clear(); | 43 printer_name_.clear(); |
| 41 device_name_.clear(); | 44 device_name_.clear(); |
| 42 page_setup_device_units_.Clear(); | 45 page_setup_device_units_.Clear(); |
| 43 dpi_ = 0; | 46 dpi_ = 0; |
| (...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 208 dpi_ == rhs.dpi_ && | 211 dpi_ == rhs.dpi_ && |
| 209 landscape_ == rhs.landscape_; | 212 landscape_ == rhs.landscape_; |
| 210 } | 213 } |
| 211 | 214 |
| 212 int PrintSettings::NewCookie() { | 215 int PrintSettings::NewCookie() { |
| 213 // A cookie of 0 is used to mark a document as unassigned, count from 1. | 216 // A cookie of 0 is used to mark a document as unassigned, count from 1. |
| 214 return cookie_seq.GetNext() + 1; | 217 return cookie_seq.GetNext() + 1; |
| 215 } | 218 } |
| 216 | 219 |
| 217 } // namespace printing | 220 } // namespace printing |
| OLD | NEW |