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

Side by Side Diff: chrome/browser/ui/webui/print_preview/print_preview_ui.cc

Issue 1125343004: Add a "Simplify Page" option to the print preview dialog (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Simplify version of the HiddenPrintPreview and solved issues pointed out by the last review Created 5 years, 5 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
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 #include "chrome/browser/ui/webui/print_preview/print_preview_ui.h" 5 #include "chrome/browser/ui/webui/print_preview/print_preview_ui.h"
6 6
7 #include <map> 7 #include <map>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/id_map.h" 10 #include "base/id_map.h"
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 IDS_PRINT_PREVIEW_PAGE_RANGE_INSTRUCTION); 244 IDS_PRINT_PREVIEW_PAGE_RANGE_INSTRUCTION);
245 source->AddLocalizedString("copiesInstruction", 245 source->AddLocalizedString("copiesInstruction",
246 IDS_PRINT_PREVIEW_COPIES_INSTRUCTION); 246 IDS_PRINT_PREVIEW_COPIES_INSTRUCTION);
247 source->AddLocalizedString("incrementTitle", 247 source->AddLocalizedString("incrementTitle",
248 IDS_PRINT_PREVIEW_INCREMENT_TITLE); 248 IDS_PRINT_PREVIEW_INCREMENT_TITLE);
249 source->AddLocalizedString("decrementTitle", 249 source->AddLocalizedString("decrementTitle",
250 IDS_PRINT_PREVIEW_DECREMENT_TITLE); 250 IDS_PRINT_PREVIEW_DECREMENT_TITLE);
251 source->AddLocalizedString("printPagesLabel", 251 source->AddLocalizedString("printPagesLabel",
252 IDS_PRINT_PREVIEW_PRINT_PAGES_LABEL); 252 IDS_PRINT_PREVIEW_PRINT_PAGES_LABEL);
253 source->AddLocalizedString("optionsLabel", IDS_PRINT_PREVIEW_OPTIONS_LABEL); 253 source->AddLocalizedString("optionsLabel", IDS_PRINT_PREVIEW_OPTIONS_LABEL);
254 source->AddLocalizedString("optionPrintFriendly",
255 IDS_PRINT_PREVIEW_OPTION_PRINT_FRIENDLY);
254 source->AddLocalizedString("optionHeaderFooter", 256 source->AddLocalizedString("optionHeaderFooter",
255 IDS_PRINT_PREVIEW_OPTION_HEADER_FOOTER); 257 IDS_PRINT_PREVIEW_OPTION_HEADER_FOOTER);
256 source->AddLocalizedString("optionFitToPage", 258 source->AddLocalizedString("optionFitToPage",
257 IDS_PRINT_PREVIEW_OPTION_FIT_TO_PAGE); 259 IDS_PRINT_PREVIEW_OPTION_FIT_TO_PAGE);
258 source->AddLocalizedString( 260 source->AddLocalizedString(
259 "optionBackgroundColorsAndImages", 261 "optionBackgroundColorsAndImages",
260 IDS_PRINT_PREVIEW_OPTION_BACKGROUND_COLORS_AND_IMAGES); 262 IDS_PRINT_PREVIEW_OPTION_BACKGROUND_COLORS_AND_IMAGES);
261 source->AddLocalizedString("optionSelectionOnly", 263 source->AddLocalizedString("optionSelectionOnly",
262 IDS_PRINT_PREVIEW_OPTION_SELECTION_ONLY); 264 IDS_PRINT_PREVIEW_OPTION_SELECTION_ONLY);
263 source->AddLocalizedString("marginsLabel", IDS_PRINT_PREVIEW_MARGINS_LABEL); 265 source->AddLocalizedString("marginsLabel", IDS_PRINT_PREVIEW_MARGINS_LABEL);
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
654 } 656 }
655 657
656 void PrintPreviewUI::SetSelectedFileForTesting(const base::FilePath& path) { 658 void PrintPreviewUI::SetSelectedFileForTesting(const base::FilePath& path) {
657 handler_->FileSelected(path, 0, NULL); 659 handler_->FileSelected(path, 0, NULL);
658 } 660 }
659 661
660 void PrintPreviewUI::SetPdfSavedClosureForTesting( 662 void PrintPreviewUI::SetPdfSavedClosureForTesting(
661 const base::Closure& closure) { 663 const base::Closure& closure) {
662 handler_->SetPdfSavedClosureForTesting(closure); 664 handler_->SetPdfSavedClosureForTesting(closure);
663 } 665 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698