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

Unified Diff: webkit/plugins/ppapi/ppb_audio_impl.cc

Issue 7585025: Reland 95309. Add a template to handle properly issuing completion callbacks. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/plugins/ppapi/ppb_audio_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppb_audio_impl.cc
===================================================================
--- webkit/plugins/ppapi/ppb_audio_impl.cc (revision 95737)
+++ webkit/plugins/ppapi/ppb_audio_impl.cc (working copy)
@@ -14,6 +14,10 @@
#include "ppapi/thunk/thunk.h"
#include "webkit/plugins/ppapi/common.h"
+using ppapi::thunk::EnterResourceNoLock;
+using ppapi::thunk::PPB_Audio_API;
+using ppapi::thunk::PPB_AudioConfig_API;
+
namespace webkit {
namespace ppapi {
@@ -37,8 +41,7 @@
return config->GetReference();
}
-::ppapi::thunk::PPB_AudioConfig_API*
-PPB_AudioConfig_Impl::AsPPB_AudioConfig_API() {
+PPB_AudioConfig_API* PPB_AudioConfig_Impl::AsPPB_AudioConfig_API() {
return this;
}
@@ -86,19 +89,14 @@
return audio->GetReference();
}
-::ppapi::thunk::PPB_Audio_API* PPB_Audio_Impl::AsPPB_Audio_API() {
+PPB_Audio_API* PPB_Audio_Impl::AsPPB_Audio_API() {
return this;
}
-::ppapi::thunk::PPB_AudioTrusted_API* PPB_Audio_Impl::AsPPB_AudioTrusted_API() {
- return this;
-}
-
bool PPB_Audio_Impl::Init(PP_Resource config_id,
PPB_Audio_Callback callback, void* user_data) {
// Validate the config and keep a reference to it.
- ::ppapi::thunk::EnterResourceNoLock< ::ppapi::thunk::PPB_AudioConfig_API>
- enter(config_id, true);
+ EnterResourceNoLock<PPB_AudioConfig_API> enter(config_id, true);
if (enter.failed())
return false;
config_id_ = config_id;
@@ -147,8 +145,7 @@
PP_CompletionCallback create_callback) {
// Validate the config and keep a reference to it.
- ::ppapi::thunk::EnterResourceNoLock< ::ppapi::thunk::PPB_AudioConfig_API>
- enter(config_id, true);
+ EnterResourceNoLock<PPB_AudioConfig_API> enter(config_id, true);
if (enter.failed())
return false;
config_id_ = config_id;
« no previous file with comments | « webkit/plugins/ppapi/ppb_audio_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698