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

Unified Diff: ppapi/shared_impl/ppapi_globals.cc

Issue 10081020: PPAPI: Make blocking completion callbacks work. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: export AssertLockHeld Created 8 years, 6 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 | « ppapi/shared_impl/ppapi_globals.h ('k') | ppapi/shared_impl/ppb_audio_config_shared.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/shared_impl/ppapi_globals.cc
diff --git a/ppapi/shared_impl/ppapi_globals.cc b/ppapi/shared_impl/ppapi_globals.cc
index c453ae2d4854b86bd3dcd568abbb66d079abd95f..80a4ee2417fc8ecb448fde261f411f8284abe73c 100644
--- a/ppapi/shared_impl/ppapi_globals.cc
+++ b/ppapi/shared_impl/ppapi_globals.cc
@@ -6,6 +6,7 @@
#include "base/lazy_instance.h" // For testing purposes only.
#include "base/logging.h"
+#include "base/message_loop_proxy.h"
#include "base/threading/thread_local.h" // For testing purposes only.
namespace ppapi {
@@ -41,6 +42,12 @@ void PpapiGlobals::SetPpapiGlobalsOnThreadForTest(PpapiGlobals* ptr) {
tls_ppapi_globals_for_test.Pointer()->Set(ptr);
}
+base::MessageLoopProxy* PpapiGlobals::GetMainThreadMessageLoop() {
+ CR_DEFINE_STATIC_LOCAL(scoped_refptr<base::MessageLoopProxy>, proxy,
+ (base::MessageLoopProxy::current()));
+ return proxy.get();
+}
+
bool PpapiGlobals::IsHostGlobals() const {
return false;
}
« no previous file with comments | « ppapi/shared_impl/ppapi_globals.h ('k') | ppapi/shared_impl/ppb_audio_config_shared.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698