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 #ifndef CHROME_RENDERER_PLUGINS_BLOCKED_PLUGIN_H_ | 5 #ifndef CHROME_RENDERER_PLUGINS_BLOCKED_PLUGIN_H_ |
6 #define CHROME_RENDERER_PLUGINS_BLOCKED_PLUGIN_H_ | 6 #define CHROME_RENDERER_PLUGINS_BLOCKED_PLUGIN_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "chrome/renderer/plugins/plugin_placeholder.h" | 9 #include "chrome/renderer/plugins/plugin_placeholder.h" |
10 #include "webkit/plugins/webplugininfo.h" | 10 #include "webkit/plugins/webplugininfo.h" |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 | 52 |
53 // Javascript callbacks: | 53 // Javascript callbacks: |
54 // Load the blocked plugin by calling LoadPlugin(). | 54 // Load the blocked plugin by calling LoadPlugin(). |
55 // Takes no arguments, and returns nothing. | 55 // Takes no arguments, and returns nothing. |
56 void LoadCallback(const CppArgumentList& args, CppVariant* result); | 56 void LoadCallback(const CppArgumentList& args, CppVariant* result); |
57 | 57 |
58 // Hide the blocked plugin by calling HidePlugin(). | 58 // Hide the blocked plugin by calling HidePlugin(). |
59 // Takes no arguments, and returns nothing. | 59 // Takes no arguments, and returns nothing. |
60 void HideCallback(const CppArgumentList& args, CppVariant* result); | 60 void HideCallback(const CppArgumentList& args, CppVariant* result); |
61 | 61 |
62 // Opens a URL in a new tab. | 62 // Opens chrome://plugins in a new tab. |
63 // Takes one argument, a string specifying the URL to open. Returns nothing. | 63 // Takes no arguments, and returns nothing. |
64 void OpenUrlCallback(const CppArgumentList& args, CppVariant* result); | 64 void OpenAboutPluginsCallback(const CppArgumentList& args, |
| 65 CppVariant* result); |
65 | 66 |
66 // Load the blocked plugin. | 67 // Load the blocked plugin. |
67 void LoadPlugin(); | 68 void LoadPlugin(); |
68 | 69 |
69 // Hide the blocked plugin. | 70 // Hide the blocked plugin. |
70 void HidePlugin(); | 71 void HidePlugin(); |
71 | 72 |
72 webkit::WebPluginInfo plugin_info_; | 73 webkit::WebPluginInfo plugin_info_; |
73 // The name of the plugin that was blocked. | 74 // The name of the plugin that was blocked. |
74 string16 name_; | 75 string16 name_; |
75 // True iff the plugin was blocked because the page was being prerendered. | 76 // True iff the plugin was blocked because the page was being prerendered. |
76 // Plugin will automatically be loaded when the page is displayed. | 77 // Plugin will automatically be loaded when the page is displayed. |
77 bool is_blocked_for_prerendering_; | 78 bool is_blocked_for_prerendering_; |
78 bool hidden_; | 79 bool hidden_; |
79 bool allow_loading_; | 80 bool allow_loading_; |
80 }; | 81 }; |
81 | 82 |
82 #endif // CHROME_RENDERER_PLUGINS_BLOCKED_PLUGIN_H_ | 83 #endif // CHROME_RENDERER_PLUGINS_BLOCKED_PLUGIN_H_ |
OLD | NEW |