| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "webkit/plugins/ppapi/ppb_font_impl.h" | 5 #include "webkit/plugins/ppapi/ppb_font_impl.h" |
| 6 | 6 |
| 7 #include "ppapi/c/dev/ppb_font_dev.h" | 7 #include "ppapi/c/dev/ppb_font_dev.h" |
| 8 #include "ppapi/shared_impl/font_impl.h" | |
| 9 #include "ppapi/shared_impl/ppapi_preferences.h" | 8 #include "ppapi/shared_impl/ppapi_preferences.h" |
| 9 #include "ppapi/shared_impl/ppb_font_shared.h" |
| 10 #include "ppapi/shared_impl/var.h" | 10 #include "ppapi/shared_impl/var.h" |
| 11 #include "ppapi/thunk/enter.h" | 11 #include "ppapi/thunk/enter.h" |
| 12 #include "ppapi/thunk/thunk.h" | 12 #include "ppapi/thunk/thunk.h" |
| 13 #include "webkit/plugins/ppapi/common.h" | 13 #include "webkit/plugins/ppapi/common.h" |
| 14 #include "webkit/plugins/ppapi/plugin_module.h" | 14 #include "webkit/plugins/ppapi/plugin_module.h" |
| 15 #include "webkit/plugins/ppapi/ppapi_plugin_instance.h" | 15 #include "webkit/plugins/ppapi/ppapi_plugin_instance.h" |
| 16 #include "webkit/plugins/ppapi/ppb_image_data_impl.h" | 16 #include "webkit/plugins/ppapi/ppb_image_data_impl.h" |
| 17 #include "webkit/plugins/ppapi/resource_helper.h" | 17 #include "webkit/plugins/ppapi/resource_helper.h" |
| 18 #include "webkit/plugins/ppapi/string.h" | 18 #include "webkit/plugins/ppapi/string.h" |
| 19 | 19 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 } | 57 } |
| 58 font_forwarding_.reset(result); | 58 font_forwarding_.reset(result); |
| 59 } | 59 } |
| 60 | 60 |
| 61 PPB_Font_Impl::~PPB_Font_Impl() { | 61 PPB_Font_Impl::~PPB_Font_Impl() { |
| 62 } | 62 } |
| 63 | 63 |
| 64 // static | 64 // static |
| 65 PP_Resource PPB_Font_Impl::Create(PP_Instance instance, | 65 PP_Resource PPB_Font_Impl::Create(PP_Instance instance, |
| 66 const PP_FontDescription_Dev& description) { | 66 const PP_FontDescription_Dev& description) { |
| 67 if (!::ppapi::FontImpl::IsPPFontDescriptionValid(description)) | 67 if (!::ppapi::PPB_Font_Shared::IsPPFontDescriptionValid(description)) |
| 68 return 0; | 68 return 0; |
| 69 return (new PPB_Font_Impl(instance, description))->GetReference(); | 69 return (new PPB_Font_Impl(instance, description))->GetReference(); |
| 70 } | 70 } |
| 71 | 71 |
| 72 ::ppapi::thunk::PPB_Font_API* PPB_Font_Impl::AsPPB_Font_API() { | 72 ::ppapi::thunk::PPB_Font_API* PPB_Font_Impl::AsPPB_Font_API() { |
| 73 return this; | 73 return this; |
| 74 } | 74 } |
| 75 | 75 |
| 76 PP_Bool PPB_Font_Impl::Describe(PP_FontDescription_Dev* description, | 76 PP_Bool PPB_Font_Impl::Describe(PP_FontDescription_Dev* description, |
| 77 PP_FontMetrics_Dev* metrics) { | 77 PP_FontMetrics_Dev* metrics) { |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 return this; | 159 return this; |
| 160 } | 160 } |
| 161 | 161 |
| 162 PP_Var PPB_Font_FunctionImpl::GetFontFamilies(PP_Instance instance) { | 162 PP_Var PPB_Font_FunctionImpl::GetFontFamilies(PP_Instance instance) { |
| 163 return PP_MakeUndefined(); | 163 return PP_MakeUndefined(); |
| 164 } | 164 } |
| 165 | 165 |
| 166 } // namespace ppapi | 166 } // namespace ppapi |
| 167 } // namespace webkit | 167 } // namespace webkit |
| 168 | 168 |
| OLD | NEW |