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

Side by Side Diff: printing/printing_context.cc

Issue 5636001: On Chrome OS, use the application locale to determine the default paper size ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Review comments addressed Created 10 years 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/printing_context.h ('k') | printing/printing_context_cairo.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/printing_context.h" 5 #include "printing/printing_context.h"
6 6
7 namespace printing { 7 namespace printing {
8 8
9 PrintingContext::PrintingContext() 9 PrintingContext::PrintingContext(const std::string& app_locale)
10 : dialog_box_dismissed_(false), 10 : dialog_box_dismissed_(false),
11 in_print_job_(false), 11 in_print_job_(false),
12 abort_printing_(false) { 12 abort_printing_(false),
13 app_locale_(app_locale) {
13 } 14 }
14 15
15 PrintingContext::~PrintingContext() { 16 PrintingContext::~PrintingContext() {
16 } 17 }
17 18
18 void PrintingContext::ResetSettings() { 19 void PrintingContext::ResetSettings() {
19 ReleaseContext(); 20 ReleaseContext();
20 21
21 settings_.Clear(); 22 settings_.Clear();
22 23
23 in_print_job_ = false; 24 in_print_job_ = false;
24 dialog_box_dismissed_ = false; 25 dialog_box_dismissed_ = false;
25 abort_printing_ = false; 26 abort_printing_ = false;
26 } 27 }
27 28
28 PrintingContext::Result PrintingContext::OnError() { 29 PrintingContext::Result PrintingContext::OnError() {
29 ResetSettings(); 30 ResetSettings();
30 return abort_printing_ ? CANCEL : FAILED; 31 return abort_printing_ ? CANCEL : FAILED;
31 } 32 }
32 33
33 } // namespace printing 34 } // namespace printing
OLDNEW
« no previous file with comments | « printing/printing_context.h ('k') | printing/printing_context_cairo.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698