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/pepper_broker_observer.h" | 5 #include "chrome/browser/pepper_broker_observer.h" |
6 | 6 |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "chrome/browser/api/infobars/confirm_infobar_delegate.h" | 8 #include "chrome/browser/api/infobars/confirm_infobar_delegate.h" |
9 #include "chrome/browser/content_settings/host_content_settings_map.h" | 9 #include "chrome/browser/content_settings/host_content_settings_map.h" |
10 #include "chrome/browser/infobars/infobar_tab_helper.h" | 10 #include "chrome/browser/infobars/infobar_tab_helper.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 #include "net/base/net_util.h" | 24 #include "net/base/net_util.h" |
25 #include "ui/base/l10n/l10n_util.h" | 25 #include "ui/base/l10n/l10n_util.h" |
26 #include "ui/base/resource/resource_bundle.h" | 26 #include "ui/base/resource/resource_bundle.h" |
27 #include "webkit/plugins/npapi/plugin_list.h" | 27 #include "webkit/plugins/npapi/plugin_list.h" |
28 #include "webkit/plugins/webplugininfo.h" | 28 #include "webkit/plugins/webplugininfo.h" |
29 | 29 |
30 using content::OpenURLParams; | 30 using content::OpenURLParams; |
31 using content::Referrer; | 31 using content::Referrer; |
32 using content::WebContents; | 32 using content::WebContents; |
33 | 33 |
34 int PepperBrokerObserver::kUserDataKey; | 34 DEFINE_WEB_CONTENTS_USER_DATA_KEY(PepperBrokerObserver) |
35 | 35 |
36 namespace { | 36 namespace { |
37 | 37 |
38 // The URL for the "learn more" article about the PPAPI broker. | 38 // The URL for the "learn more" article about the PPAPI broker. |
39 const char kPpapiBrokerLearnMoreUrl[] = | 39 const char kPpapiBrokerLearnMoreUrl[] = |
40 "https://support.google.com/chrome/?p=ib_pepper_broker"; | 40 "https://support.google.com/chrome/?p=ib_pepper_broker"; |
41 | 41 |
42 class PepperBrokerInfoBarDelegate : public ConfirmInfoBarDelegate { | 42 class PepperBrokerInfoBarDelegate : public ConfirmInfoBarDelegate { |
43 public: | 43 public: |
44 static void Show( | 44 static void Show( |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 infobar_helper, url, plugin_path, languages, content_settings, | 224 infobar_helper, url, plugin_path, languages, content_settings, |
225 callback)); | 225 callback)); |
226 break; | 226 break; |
227 } | 227 } |
228 default: | 228 default: |
229 NOTREACHED(); | 229 NOTREACHED(); |
230 } | 230 } |
231 | 231 |
232 return true; | 232 return true; |
233 } | 233 } |
OLD | NEW |