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

Side by Side Diff: components/plugins/renderer/loadable_plugin_placeholder.h

Issue 1148223004: Plugin Placeholders: Factor out common BindWebFrame method into base class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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
« no previous file with comments | « no previous file | components/plugins/renderer/loadable_plugin_placeholder.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 COMPONENTS_PLUGINS_RENDERER_LOADABLE_PLUGIN_PLACEHOLDER_H_ 5 #ifndef COMPONENTS_PLUGINS_RENDERER_LOADABLE_PLUGIN_PLACEHOLDER_H_
6 #define COMPONENTS_PLUGINS_RENDERER_LOADABLE_PLUGIN_PLACEHOLDER_H_ 6 #define COMPONENTS_PLUGINS_RENDERER_LOADABLE_PLUGIN_PLACEHOLDER_H_
7 7
8 #include "base/memory/weak_ptr.h" 8 #include "base/memory/weak_ptr.h"
9 #include "components/plugins/renderer/plugin_placeholder.h" 9 #include "components/plugins/renderer/plugin_placeholder.h"
10 #include "content/public/common/webplugininfo.h" 10 #include "content/public/common/webplugininfo.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 // Replace this placeholder with a different plugin (which could be 66 // Replace this placeholder with a different plugin (which could be
67 // a placeholder again). 67 // a placeholder again).
68 void ReplacePlugin(blink::WebPlugin* new_plugin); 68 void ReplacePlugin(blink::WebPlugin* new_plugin);
69 69
70 // Hide this placeholder. 70 // Hide this placeholder.
71 void HidePlugin(); 71 void HidePlugin();
72 72
73 // Load the blocked plugin. 73 // Load the blocked plugin.
74 void LoadPlugin(); 74 void LoadPlugin();
75 75
76 // WebViewPlugin::Delegate (via PluginPlaceholder) method
77 void BindWebFrame(blink::WebFrame* frame) override;
78
79 // gin::Wrappable method: 76 // gin::Wrappable method:
80 gin::ObjectTemplateBuilder GetObjectTemplateBuilder( 77 gin::ObjectTemplateBuilder GetObjectTemplateBuilder(
81 v8::Isolate* isolate) override; 78 v8::Isolate* isolate) override;
82 79
83 private: 80 private:
84 // WebViewPlugin::Delegate methods: 81 // WebViewPlugin::Delegate methods:
85 void PluginDestroyed() override; 82 void PluginDestroyed() override;
86 v8::Local<v8::Object> GetV8ScriptableObject( 83 v8::Local<v8::Object> GetV8ScriptableObject(
87 v8::Isolate* isolate) const override; 84 v8::Isolate* isolate) const override;
88 85
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 std::string identifier_; 127 std::string identifier_;
131 128
132 base::WeakPtrFactory<LoadablePluginPlaceholder> weak_factory_; 129 base::WeakPtrFactory<LoadablePluginPlaceholder> weak_factory_;
133 130
134 DISALLOW_COPY_AND_ASSIGN(LoadablePluginPlaceholder); 131 DISALLOW_COPY_AND_ASSIGN(LoadablePluginPlaceholder);
135 }; 132 };
136 133
137 } // namespace plugins 134 } // namespace plugins
138 135
139 #endif // COMPONENTS_PLUGINS_RENDERER_LOADABLE_PLUGIN_PLACEHOLDER_H_ 136 #endif // COMPONENTS_PLUGINS_RENDERER_LOADABLE_PLUGIN_PLACEHOLDER_H_
OLDNEW
« no previous file with comments | « no previous file | components/plugins/renderer/loadable_plugin_placeholder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698