OLD | NEW |
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/pdf_unsupported_feature.h" | 5 #include "chrome/browser/pdf_unsupported_feature.h" |
6 | 6 |
7 #include "app/l10n_util.h" | |
8 #include "app/resource_bundle.h" | |
9 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
10 #include "base/values.h" | 8 #include "base/values.h" |
11 #include "base/version.h" | 9 #include "base/version.h" |
12 #include "chrome/browser/plugin_service.h" | 10 #include "chrome/browser/plugin_service.h" |
13 #include "chrome/browser/renderer_host/render_process_host.h" | 11 #include "chrome/browser/renderer_host/render_process_host.h" |
14 #include "chrome/browser/renderer_host/render_view_host.h" | 12 #include "chrome/browser/renderer_host/render_view_host.h" |
15 #include "chrome/browser/tab_contents/infobar_delegate.h" | 13 #include "chrome/browser/tab_contents/infobar_delegate.h" |
16 #include "chrome/browser/tab_contents/interstitial_page.h" | 14 #include "chrome/browser/tab_contents/interstitial_page.h" |
17 #include "chrome/browser/tab_contents/tab_contents.h" | 15 #include "chrome/browser/tab_contents/tab_contents.h" |
18 #include "chrome/common/jstemplate_builder.h" | 16 #include "chrome/common/jstemplate_builder.h" |
19 #include "grit/browser_resources.h" | 17 #include "grit/browser_resources.h" |
20 #include "grit/generated_resources.h" | 18 #include "grit/generated_resources.h" |
| 19 #include "ui/base/l10n/l10n_util.h" |
| 20 #include "ui/base/resource/resource_bundle.h" |
21 #include "webkit/plugins/npapi/plugin_group.h" | 21 #include "webkit/plugins/npapi/plugin_group.h" |
22 #include "webkit/plugins/npapi/plugin_list.h" | 22 #include "webkit/plugins/npapi/plugin_list.h" |
23 #include "webkit/plugins/npapi/webplugininfo.h" | 23 #include "webkit/plugins/npapi/webplugininfo.h" |
24 | 24 |
25 using webkit::npapi::PluginGroup; | 25 using webkit::npapi::PluginGroup; |
26 using webkit::npapi::PluginList; | 26 using webkit::npapi::PluginList; |
27 using webkit::npapi::WebPluginInfo; | 27 using webkit::npapi::WebPluginInfo; |
28 | 28 |
29 // Only launch Adobe Reader X or later. | 29 // Only launch Adobe Reader X or later. |
30 static const uint16 kMinReaderVersionToUse = 10; | 30 static const uint16 kMinReaderVersionToUse = 10; |
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
222 } | 222 } |
223 } | 223 } |
224 | 224 |
225 // If the plugin is disabled by policy or by the user, don't prompt them. | 225 // If the plugin is disabled by policy or by the user, don't prompt them. |
226 if (reader_group && !reader_group->Enabled()) | 226 if (reader_group && !reader_group->Enabled()) |
227 return; | 227 return; |
228 | 228 |
229 tab->AddInfoBar(new PDFUnsupportedFeatureConfirmInfoBarDelegate( | 229 tab->AddInfoBar(new PDFUnsupportedFeatureConfirmInfoBarDelegate( |
230 tab, reader_group)); | 230 tab, reader_group)); |
231 } | 231 } |
OLD | NEW |