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

Unified Diff: ppapi/thunk/ppb_flash_thunk.cc

Issue 11510008: Refactor 4 PPB_Flash functions to the new PPAPI resource model. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ppapi/thunk/ppb_flash_functions_api.h ('k') | webkit/plugins/ppapi/ppb_flash_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/thunk/ppb_flash_thunk.cc
diff --git a/ppapi/thunk/ppb_flash_thunk.cc b/ppapi/thunk/ppb_flash_thunk.cc
index b9735f43efb642f586ef8fbfc96f99349ab9c72e..c4e27f1ad3b4122c0f699a6d119026fbe8b79dfb 100644
--- a/ppapi/thunk/ppb_flash_thunk.cc
+++ b/ppapi/thunk/ppb_flash_thunk.cc
@@ -22,10 +22,10 @@ namespace thunk {
namespace {
void SetInstanceAlwaysOnTop(PP_Instance instance, PP_Bool on_top) {
- EnterInstance enter(instance);
+ EnterInstanceAPI<PPB_Flash_Functions_API> enter(instance);
if (enter.failed())
return;
- enter.functions()->GetFlashAPI()->SetInstanceAlwaysOnTop(instance, on_top);
+ enter.functions()->SetInstanceAlwaysOnTop(instance, on_top);
}
PP_Bool DrawGlyphs(PP_Instance instance,
@@ -39,10 +39,10 @@ PP_Bool DrawGlyphs(PP_Instance instance,
uint32_t glyph_count,
const uint16_t glyph_indices[],
const PP_Point glyph_advances[]) {
- EnterInstance enter(instance);
+ EnterInstanceAPI<PPB_Flash_Functions_API> enter(instance);
if (enter.failed())
return PP_FALSE;
- return enter.functions()->GetFlashAPI()->DrawGlyphs(
+ return enter.functions()->DrawGlyphs(
instance, pp_image_data, font_desc, color, position, clip, transformation,
allow_subpixel_aa, glyph_count, glyph_indices, glyph_advances);
}
@@ -67,11 +67,11 @@ int32_t Navigate(PP_Resource request_id,
instance = enter.resource()->pp_instance();
}
- EnterInstance enter(instance);
+ EnterInstanceAPI<PPB_Flash_Functions_API> enter(instance);
if (enter.failed())
return PP_ERROR_BADARGUMENT;
- return enter.functions()->GetFlashAPI()->Navigate(instance, request_id,
- target, from_user_action);
+ return enter.functions()->Navigate(instance, request_id, target,
+ from_user_action);
}
void RunMessageLoop(PP_Instance instance) {
@@ -107,10 +107,10 @@ void PreLoadFontWin(const void* logfontw) {
}
PP_Bool IsRectTopmost(PP_Instance instance, const PP_Rect* rect) {
- EnterInstance enter(instance);
+ EnterInstanceAPI<PPB_Flash_Functions_API> enter(instance);
if (enter.failed())
return PP_FALSE;
- return enter.functions()->GetFlashAPI()->IsRectTopmost(instance, rect);
+ return enter.functions()->IsRectTopmost(instance, rect);
}
int32_t InvokePrinting(PP_Instance instance) {
« no previous file with comments | « ppapi/thunk/ppb_flash_functions_api.h ('k') | webkit/plugins/ppapi/ppb_flash_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698