| Index: webkit/plugins/ppapi/ppb_font_impl.cc
|
| diff --git a/webkit/plugins/ppapi/ppb_font_impl.cc b/webkit/plugins/ppapi/ppb_font_impl.cc
|
| index 8db4ed67fbc74671a76b340557328759212fdf29..a80c7e5171de1008f44a37c993f4315d8ae0c717 100644
|
| --- a/webkit/plugins/ppapi/ppb_font_impl.cc
|
| +++ b/webkit/plugins/ppapi/ppb_font_impl.cc
|
| @@ -14,6 +14,7 @@
|
| #include "webkit/plugins/ppapi/plugin_module.h"
|
| #include "webkit/plugins/ppapi/ppapi_plugin_instance.h"
|
| #include "webkit/plugins/ppapi/ppb_image_data_impl.h"
|
| +#include "webkit/plugins/ppapi/resource_helper.h"
|
| #include "webkit/plugins/ppapi/string.h"
|
|
|
| using ppapi::StringVar;
|
| @@ -42,11 +43,12 @@ bool PPTextRunToTextRun(const PP_TextRun_Dev* run,
|
|
|
| } // namespace
|
|
|
| -PPB_Font_Impl::PPB_Font_Impl(PluginInstance* instance,
|
| +PPB_Font_Impl::PPB_Font_Impl(PP_Instance pp_instance,
|
| const PP_FontDescription_Dev& desc)
|
| - : Resource(instance) {
|
| + : Resource(pp_instance) {
|
| StringVar* face_name = StringVar::FromPPVar(desc.face);
|
|
|
| + PluginInstance* instance = ResourceHelper::GetPluginInstance(this);
|
| WebKitForwarding::Font* result = NULL;
|
| instance->module()->GetWebKitForwarding()->CreateFontForwarding(
|
| NULL, desc, face_name ? face_name->value() : std::string(),
|
| @@ -58,7 +60,7 @@ PPB_Font_Impl::~PPB_Font_Impl() {
|
| }
|
|
|
| // static
|
| -PP_Resource PPB_Font_Impl::Create(PluginInstance* instance,
|
| +PP_Resource PPB_Font_Impl::Create(PP_Instance instance,
|
| const PP_FontDescription_Dev& description) {
|
| if (!::ppapi::FontImpl::IsPPFontDescriptionValid(description))
|
| return 0;
|
| @@ -79,7 +81,7 @@ PP_Bool PPB_Font_Impl::Describe(PP_FontDescription_Dev* description,
|
|
|
| // Convert the string.
|
| description->face = StringVar::StringToPPVar(
|
| - instance()->module()->pp_module(), face);
|
| + ResourceHelper::GetPluginModule(this)->pp_module(), face);
|
| return PP_TRUE;
|
| }
|
|
|
|
|