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

Side by Side Diff: printing/print_settings.cc

Issue 7585015: Printing: Remove unused PageOverlay since header/footers are drawn in PrintWebViewHelper. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix win Created 9 years, 4 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/print_settings.h ('k') | printing/printed_document.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) 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 "printing/units.h" 8 #include "printing/units.h"
9 9
10 namespace printing { 10 namespace printing {
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 } 75 }
76 76
77 bool PrintSettings::Equals(const PrintSettings& rhs) const { 77 bool PrintSettings::Equals(const PrintSettings& rhs) const {
78 // Do not test the display device name (printer_name_) for equality since it 78 // Do not test the display device name (printer_name_) for equality since it
79 // may sometimes be chopped off at 30 chars. As long as device_name is the 79 // may sometimes be chopped off at 30 chars. As long as device_name is the
80 // same, that's fine. 80 // same, that's fine.
81 return ranges == rhs.ranges && 81 return ranges == rhs.ranges &&
82 min_shrink == rhs.min_shrink && 82 min_shrink == rhs.min_shrink &&
83 max_shrink == rhs.max_shrink && 83 max_shrink == rhs.max_shrink &&
84 desired_dpi == rhs.desired_dpi && 84 desired_dpi == rhs.desired_dpi &&
85 overlays.Equals(rhs.overlays) &&
86 device_name_ == rhs.device_name_ && 85 device_name_ == rhs.device_name_ &&
87 page_setup_device_units_.Equals(rhs.page_setup_device_units_) && 86 page_setup_device_units_.Equals(rhs.page_setup_device_units_) &&
88 dpi_ == rhs.dpi_ && 87 dpi_ == rhs.dpi_ &&
89 landscape_ == rhs.landscape_; 88 landscape_ == rhs.landscape_;
90 } 89 }
91 90
92 int PrintSettings::NewCookie() { 91 int PrintSettings::NewCookie() {
93 // A cookie of 0 is used to mark a document as unassigned, count from 1. 92 // A cookie of 0 is used to mark a document as unassigned, count from 1.
94 return cookie_seq.GetNext() + 1; 93 return cookie_seq.GetNext() + 1;
95 } 94 }
96 95
97 void PrintSettings::SetOrientation(bool landscape) { 96 void PrintSettings::SetOrientation(bool landscape) {
98 if (landscape_ != landscape) { 97 if (landscape_ != landscape) {
99 landscape_ = landscape; 98 landscape_ = landscape;
100 page_setup_device_units_.FlipOrientation(); 99 page_setup_device_units_.FlipOrientation();
101 } 100 }
102 } 101 }
103 102
104 } // namespace printing 103 } // namespace printing
OLDNEW
« no previous file with comments | « printing/print_settings.h ('k') | printing/printed_document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698