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

Unified Diff: content/shell/shell_plugin_service_filter.h

Issue 16059004: [content shell] only allow test plugins to load during layout tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: content/shell/shell_plugin_service_filter.h
diff --git a/content/shell/shell_plugin_service_filter.h b/content/shell/shell_plugin_service_filter.h
new file mode 100644
index 0000000000000000000000000000000000000000..81f80636ca6b248bde3e7d51498105d96b73a904
--- /dev/null
+++ b/content/shell/shell_plugin_service_filter.h
@@ -0,0 +1,37 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_SHELL_SHELL_PLUGIN_SERVICE_FILTER_H_
+#define CONTENT_SHELL_SHELL_PLUGIN_SERVICE_FILTER_H_
+
+#include "base/basictypes.h"
+#include "base/compiler_specific.h"
+#include "content/public/browser/plugin_service_filter.h"
+
+namespace content {
+
+class ShellPluginServiceFilter : public PluginServiceFilter {
+ public:
+ ShellPluginServiceFilter();
+ virtual ~ShellPluginServiceFilter();
+
+ // PluginServiceFilter implementation.
+ virtual bool IsPluginAvailable(int render_process_id,
+ int render_view_id,
+ const void* context,
+ const GURL& url,
+ const GURL& policy_url,
+ webkit::WebPluginInfo* plugin) OVERRIDE;
+
+ virtual bool CanLoadPlugin(int render_process_id,
+ const base::FilePath& path) OVERRIDE;
+
+ private:
+
+ DISALLOW_COPY_AND_ASSIGN(ShellPluginServiceFilter);
+};
+
+} // namespace content
+
+#endif // CONTENT_SHELL_SHELL_PLUGIN_SERVICE_FILTER_H_

Powered by Google App Engine
This is Rietveld 408576698