| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "content/browser/mock_content_browser_client.h" | |
| 6 | |
| 7 #include <string> | |
| 8 | |
| 9 #include "base/file_path.h" | |
| 10 #include "base/logging.h" | |
| 11 #include "content/test/test_web_contents_view.h" | |
| 12 #include "googleurl/src/gurl.h" | |
| 13 #include "third_party/skia/include/core/SkBitmap.h" | |
| 14 #include "ui/base/clipboard/clipboard.h" | |
| 15 | |
| 16 namespace content { | |
| 17 | |
| 18 MockContentBrowserClient::MockContentBrowserClient() { | |
| 19 } | |
| 20 | |
| 21 MockContentBrowserClient::~MockContentBrowserClient() { | |
| 22 } | |
| 23 | |
| 24 WebContentsView* MockContentBrowserClient::OverrideCreateWebContentsView( | |
| 25 WebContents* web_contents, | |
| 26 RenderViewHostDelegateView** render_view_host_delegate_view) { | |
| 27 TestWebContentsView* rv = new TestWebContentsView; | |
| 28 *render_view_host_delegate_view = rv; | |
| 29 return rv; | |
| 30 } | |
| 31 | |
| 32 FilePath MockContentBrowserClient::GetDefaultDownloadDirectory() { | |
| 33 if (!download_dir_.IsValid()) { | |
| 34 bool result = download_dir_.CreateUniqueTempDir(); | |
| 35 CHECK(result); | |
| 36 } | |
| 37 return download_dir_.path(); | |
| 38 } | |
| 39 | |
| 40 } // namespace content | |
| OLD | NEW |