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

Side by Side Diff: chrome/browser/ui/webui/print_preview_data_source.cc

Issue 7599006: Fix GOOGLE_CHROME_BUILD case. TBR=estade (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: 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 | « no previous file | no next file » | 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 "chrome/browser/ui/webui/print_preview_data_source.h" 5 #include "chrome/browser/ui/webui/print_preview_data_source.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "base/string_number_conversions.h" 10 #include "base/string_number_conversions.h"
(...skipping 11 matching lines...) Expand all
22 #include "grit/google_chrome_strings.h" 22 #include "grit/google_chrome_strings.h"
23 #include "ui/base/l10n/l10n_util.h" 23 #include "ui/base/l10n/l10n_util.h"
24 #include "ui/base/resource/resource_bundle.h" 24 #include "ui/base/resource/resource_bundle.h"
25 25
26 PrintPreviewDataSource::PrintPreviewDataSource() 26 PrintPreviewDataSource::PrintPreviewDataSource()
27 : ChromeWebUIDataSource(chrome::kChromeUIPrintHost) { 27 : ChromeWebUIDataSource(chrome::kChromeUIPrintHost) {
28 28
29 AddLocalizedString("title", IDS_PRINT_PREVIEW_TITLE); 29 AddLocalizedString("title", IDS_PRINT_PREVIEW_TITLE);
30 AddLocalizedString("loading", IDS_PRINT_PREVIEW_LOADING); 30 AddLocalizedString("loading", IDS_PRINT_PREVIEW_LOADING);
31 #if defined(GOOGLE_CHROME_BUILD) 31 #if defined(GOOGLE_CHROME_BUILD)
32 AddString("noPlugin", l10n_util::GetStringFUTF8( 32 AddString("noPlugin", l10n_util::GetStringFUTF16(
33 IDS_PRINT_PREVIEW_NO_PLUGIN, ASCIIToUTF16("chrome://plugins/")); 33 IDS_PRINT_PREVIEW_NO_PLUGIN, ASCIIToUTF16("chrome://plugins/")));
34 #else 34 #else
35 AddLocalizedString("noPlugin", IDS_PRINT_PREVIEW_NO_PLUGIN); 35 AddLocalizedString("noPlugin", IDS_PRINT_PREVIEW_NO_PLUGIN);
36 #endif 36 #endif
37 AddLocalizedString("launchNativeDialog", IDS_PRINT_PREVIEW_NATIVE_DIALOG); 37 AddLocalizedString("launchNativeDialog", IDS_PRINT_PREVIEW_NATIVE_DIALOG);
38 AddLocalizedString("previewFailed", IDS_PRINT_PREVIEW_FAILED); 38 AddLocalizedString("previewFailed", IDS_PRINT_PREVIEW_FAILED);
39 AddLocalizedString("initiatorTabClosed", 39 AddLocalizedString("initiatorTabClosed",
40 IDS_PRINT_PREVIEW_INITIATOR_TAB_CLOSED); 40 IDS_PRINT_PREVIEW_INITIATOR_TAB_CLOSED);
41 AddLocalizedString("reopenPage", IDS_PRINT_PREVIEW_REOPEN_PAGE); 41 AddLocalizedString("reopenPage", IDS_PRINT_PREVIEW_REOPEN_PAGE);
42 42
43 AddLocalizedString("printButton", IDS_PRINT_PREVIEW_PRINT_BUTTON); 43 AddLocalizedString("printButton", IDS_PRINT_PREVIEW_PRINT_BUTTON);
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 url_substr[0], page_index, &data); 121 url_substr[0], page_index, &data);
122 } 122 }
123 if (data.get()) { 123 if (data.get()) {
124 SendResponse(request_id, data); 124 SendResponse(request_id, data);
125 return; 125 return;
126 } 126 }
127 // Invalid request. 127 // Invalid request.
128 scoped_refptr<RefCountedBytes> empty_bytes(new RefCountedBytes); 128 scoped_refptr<RefCountedBytes> empty_bytes(new RefCountedBytes);
129 SendResponse(request_id, empty_bytes); 129 SendResponse(request_id, empty_bytes);
130 } 130 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698