Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 228 source->AddLocalizedString("selectButton", | 228 source->AddLocalizedString("selectButton", |
| 229 IDS_PRINT_PREVIEW_BUTTON_SELECT); | 229 IDS_PRINT_PREVIEW_BUTTON_SELECT); |
| 230 source->AddLocalizedString("goBackButton", | 230 source->AddLocalizedString("goBackButton", |
| 231 IDS_PRINT_PREVIEW_BUTTON_GO_BACK); | 231 IDS_PRINT_PREVIEW_BUTTON_GO_BACK); |
| 232 source->AddLocalizedString( | 232 source->AddLocalizedString( |
| 233 "resolveExtensionUSBPermissionMessage", | 233 "resolveExtensionUSBPermissionMessage", |
| 234 IDS_PRINT_PREVIEW_RESOLVE_EXTENSION_USB_PERMISSION_MESSAGE); | 234 IDS_PRINT_PREVIEW_RESOLVE_EXTENSION_USB_PERMISSION_MESSAGE); |
| 235 source->AddLocalizedString( | 235 source->AddLocalizedString( |
| 236 "resolveExtensionUSBErrorMessage", | 236 "resolveExtensionUSBErrorMessage", |
| 237 IDS_PRINT_PREVIEW_RESOLVE_EXTENSION_USB_ERROR_MESSAGE); | 237 IDS_PRINT_PREVIEW_RESOLVE_EXTENSION_USB_ERROR_MESSAGE); |
| 238 source->AddLocalizedString( | |
| 239 "resolveCrosPrinterMessage", | |
| 240 IDS_PRINT_PREVIEW_RESOLVE_CROS_DESTINATION_MESSAGE); | |
| 241 const base::string16 shortcut_text(base::UTF8ToUTF16(kBasicPrintShortcut)); | 238 const base::string16 shortcut_text(base::UTF8ToUTF16(kBasicPrintShortcut)); |
|
Lei Zhang
2017/03/30 23:37:56
Move this inside #else?
xdai1
2017/03/30 23:47:21
Sorry! Missed this in your previous comment. Done.
| |
| 242 #if !defined(OS_CHROMEOS) | 239 #if defined(OS_CHROMEOS) |
| 240 source->AddLocalizedString("configuringInProgressText", | |
| 241 IDS_PRINT_CONFIGURING_IN_PROGRESS_TEXT); | |
| 242 source->AddLocalizedString("configuringFailedText", | |
| 243 IDS_PRINT_CONFIGURING_FAILED_TEXT); | |
| 244 #else | |
| 243 source->AddString( | 245 source->AddString( |
| 244 "systemDialogOption", | 246 "systemDialogOption", |
| 245 l10n_util::GetStringFUTF16( | 247 l10n_util::GetStringFUTF16( |
| 246 IDS_PRINT_PREVIEW_SYSTEM_DIALOG_OPTION, | 248 IDS_PRINT_PREVIEW_SYSTEM_DIALOG_OPTION, |
| 247 shortcut_text)); | 249 shortcut_text)); |
| 248 #endif | 250 #endif |
| 249 #if defined(OS_MACOSX) | 251 #if defined(OS_MACOSX) |
| 250 source->AddLocalizedString("openPdfInPreviewOption", | 252 source->AddLocalizedString("openPdfInPreviewOption", |
| 251 IDS_PRINT_PREVIEW_OPEN_PDF_IN_PREVIEW_APP); | 253 IDS_PRINT_PREVIEW_OPEN_PDF_IN_PREVIEW_APP); |
| 252 #endif | 254 #endif |
| (...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 689 } | 691 } |
| 690 | 692 |
| 691 void PrintPreviewUI::SetSelectedFileForTesting(const base::FilePath& path) { | 693 void PrintPreviewUI::SetSelectedFileForTesting(const base::FilePath& path) { |
| 692 handler_->FileSelected(path, 0, NULL); | 694 handler_->FileSelected(path, 0, NULL); |
| 693 } | 695 } |
| 694 | 696 |
| 695 void PrintPreviewUI::SetPdfSavedClosureForTesting( | 697 void PrintPreviewUI::SetPdfSavedClosureForTesting( |
| 696 const base::Closure& closure) { | 698 const base::Closure& closure) { |
| 697 handler_->SetPdfSavedClosureForTesting(closure); | 699 handler_->SetPdfSavedClosureForTesting(closure); |
| 698 } | 700 } |
| OLD | NEW |