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

Side by Side Diff: content/test/test_content_client.cc

Issue 10383006: Add scale factor and 2x resources from webkit and plumb through to ContentClient. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add more test class GetImageResource methods. Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « content/test/test_content_client.h ('k') | ui/compositor/test/compositor_test_support.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 (c) 2012 The Chromium Authors. All rights reserved. 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 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 #include "content/test/test_content_client.h" 5 #include "content/test/test_content_client.h"
6 6
7 #include "base/base_paths.h" 7 #include "base/base_paths.h"
8 #include "base/file_path.h" 8 #include "base/file_path.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 string16 TestContentClient::GetLocalizedString(int message_id) const { 57 string16 TestContentClient::GetLocalizedString(int message_id) const {
58 return string16(); 58 return string16();
59 } 59 }
60 60
61 base::StringPiece TestContentClient::GetDataResource(int resource_id) const { 61 base::StringPiece TestContentClient::GetDataResource(int resource_id) const {
62 base::StringPiece resource; 62 base::StringPiece resource;
63 data_pack_.GetStringPiece(resource_id, &resource); 63 data_pack_.GetStringPiece(resource_id, &resource);
64 return resource; 64 return resource;
65 } 65 }
66 66
67 base::StringPiece TestContentClient::GetImageResource(
68 int resource_id,
69 float scale_factor) const {
70 base::StringPiece resource;
71 data_pack_.GetStringPiece(resource_id, &resource);
72 return resource;
73 }
74
67 #if defined(OS_WIN) 75 #if defined(OS_WIN)
68 bool TestContentClient::SandboxPlugin(CommandLine* command_line, 76 bool TestContentClient::SandboxPlugin(CommandLine* command_line,
69 sandbox::TargetPolicy* policy) { 77 sandbox::TargetPolicy* policy) {
70 return false; 78 return false;
71 } 79 }
72 #endif 80 #endif
73 81
74 #if defined(OS_MACOSX) 82 #if defined(OS_MACOSX)
75 bool TestContentClient::GetSandboxProfileForSandboxType( 83 bool TestContentClient::GetSandboxProfileForSandboxType(
76 int sandbox_type, 84 int sandbox_type,
77 int* sandbox_profile_resource_id) const { 85 int* sandbox_profile_resource_id) const {
78 return false; 86 return false;
79 } 87 }
80 #endif 88 #endif
OLDNEW
« no previous file with comments | « content/test/test_content_client.h ('k') | ui/compositor/test/compositor_test_support.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698