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

Unified Diff: content/renderer/mock_content_renderer_client.h

Issue 7274031: Wholesale move of debugger sources to content. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add OWNERS and DEPS. Created 9 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/mock_content_renderer_client.h
diff --git a/content/renderer/mock_content_renderer_client.h b/content/renderer/mock_content_renderer_client.h
new file mode 100644
index 0000000000000000000000000000000000000000..32af9a21fb61726286fe8d6020da7f992d14f481
--- /dev/null
+++ b/content/renderer/mock_content_renderer_client.h
@@ -0,0 +1,58 @@
+// Copyright (c) 2011 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_RENDERER_MOCK_CONTENT_RENDERER_CLIENT_H_
+#define CONTENT_RENDERER_MOCK_CONTENT_RENDERER_CLIENT_H_
+#pragma once
+
+#include "base/compiler_specific.h"
+#include "content/renderer/content_renderer_client.h"
+
+namespace content {
+
+// Base class for unit tests that need to mock the ContentRendererClient.
+class MockContentRendererClient : public ContentRendererClient {
+ public:
+ virtual ~MockContentRendererClient();
+ virtual void RenderThreadStarted() OVERRIDE;
+ virtual void RenderViewCreated(RenderView* render_view) OVERRIDE;
+ virtual void SetNumberOfViews(int number_of_views) OVERRIDE;
+ virtual SkBitmap* GetSadPluginBitmap() OVERRIDE;
+ virtual std::string GetDefaultEncoding() OVERRIDE;
+ virtual WebKit::WebPlugin* CreatePlugin(
+ RenderView* render_view,
+ WebKit::WebFrame* frame,
+ const WebKit::WebPluginParams& params) OVERRIDE;
+ virtual void ShowErrorPage(RenderView* render_view,
+ WebKit::WebFrame* frame,
+ int http_status_code) OVERRIDE;
+ virtual std::string GetNavigationErrorHtml(
+ const WebKit::WebURLRequest& failed_request,
+ const WebKit::WebURLError& error) OVERRIDE;
+ virtual bool RunIdleHandlerWhenWidgetsHidden() OVERRIDE;
+ virtual bool AllowPopup(const GURL& creator) OVERRIDE;
+ virtual bool ShouldFork(WebKit::WebFrame* frame,
+ const GURL& url,
+ bool is_content_initiated,
+ bool* send_referrer) OVERRIDE;
+ virtual bool WillSendRequest(WebKit::WebFrame* frame,
+ const GURL& url,
+ GURL* new_url) OVERRIDE;
+ virtual bool ShouldPumpEventsDuringCookieMessage() OVERRIDE;
+ virtual void DidCreateScriptContext(WebKit::WebFrame* frame) OVERRIDE;
+ virtual void DidDestroyScriptContext(WebKit::WebFrame* frame) OVERRIDE;
+ virtual void DidCreateIsolatedScriptContext(
+ WebKit::WebFrame* frame) OVERRIDE;
+ virtual unsigned long long VisitedLinkHash(const char* canonical_url,
+ size_t length) OVERRIDE;
+ virtual bool IsLinkVisited(unsigned long long link_hash) OVERRIDE;
+ virtual void PrefetchHostName(const char* hostname, size_t length) OVERRIDE;
+ virtual bool ShouldOverridePageVisibilityState(
+ const RenderView* render_view,
+ WebKit::WebPageVisibilityState* override_state) const OVERRIDE;
+};
+
+} // namespace content
+
+#endif // CONTENT_RENDERER_MOCK_CONTENT_RENDERER_CLIENT_H_

Powered by Google App Engine
This is Rietveld 408576698