| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "chromecast/common/cast_content_client.h" | 5 #include "chromecast/common/cast_content_client.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
| 10 #include "base/sys_info.h" | 10 #include "base/sys_info.h" |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 | 100 |
| 101 base::StringPiece CastContentClient::GetDataResource( | 101 base::StringPiece CastContentClient::GetDataResource( |
| 102 int resource_id, | 102 int resource_id, |
| 103 ui::ScaleFactor scale_factor) const { | 103 ui::ScaleFactor scale_factor) const { |
| 104 return ui::ResourceBundle::GetSharedInstance().GetRawDataResourceForScale( | 104 return ui::ResourceBundle::GetSharedInstance().GetRawDataResourceForScale( |
| 105 resource_id, scale_factor); | 105 resource_id, scale_factor); |
| 106 } | 106 } |
| 107 | 107 |
| 108 base::RefCountedMemory* CastContentClient::GetDataResourceBytes( | 108 base::RefCountedMemory* CastContentClient::GetDataResourceBytes( |
| 109 int resource_id) const { | 109 int resource_id) const { |
| 110 return ui::ResourceBundle::GetSharedInstance().LoadDataResourceBytes( | 110 return ui::ResourceBundle::GetSharedInstance().LoadLocalizedResourceBytes( |
| 111 resource_id); | 111 resource_id); |
| 112 } | 112 } |
| 113 | 113 |
| 114 gfx::Image& CastContentClient::GetNativeImageNamed(int resource_id) const { | 114 gfx::Image& CastContentClient::GetNativeImageNamed(int resource_id) const { |
| 115 return ui::ResourceBundle::GetSharedInstance().GetNativeImageNamed( | 115 return ui::ResourceBundle::GetSharedInstance().GetNativeImageNamed( |
| 116 resource_id); | 116 resource_id); |
| 117 } | 117 } |
| 118 | 118 |
| 119 #if defined(OS_ANDROID) | 119 #if defined(OS_ANDROID) |
| 120 ::media::MediaClientAndroid* CastContentClient::GetMediaClientAndroid() { | 120 ::media::MediaClientAndroid* CastContentClient::GetMediaClientAndroid() { |
| 121 return new media::CastMediaClientAndroid(); | 121 return new media::CastMediaClientAndroid(); |
| 122 } | 122 } |
| 123 #endif // OS_ANDROID | 123 #endif // OS_ANDROID |
| 124 | 124 |
| 125 } // namespace shell | 125 } // namespace shell |
| 126 } // namespace chromecast | 126 } // namespace chromecast |
| OLD | NEW |