summaryrefslogtreecommitdiffstats
path: root/ppapi
diff options
context:
space:
mode:
authordhollowa@chromium.org <dhollowa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-14 19:33:52 +0000
committerdhollowa@chromium.org <dhollowa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-14 19:33:52 +0000
commitb5717a4f9f66283a9fe04ae1f9a3a89920d5b6b0 (patch)
tree9d14cf64e2cbeed63b232ba09a8c1274280d81b0 /ppapi
parentbbdfcab9e264df0f264f56d8cb5f7ef61e5f96b6 (diff)
downloadchromium_src-b5717a4f9f66283a9fe04ae1f9a3a89920d5b6b0.zip
chromium_src-b5717a4f9f66283a9fe04ae1f9a3a89920d5b6b0.tar.gz
chromium_src-b5717a4f9f66283a9fe04ae1f9a3a89920d5b6b0.tar.bz2
Prefer ScopedNestableTaskAllower over manual save/restore
Cleanup. Changes various calls sites to use the ScopedNestableTaskAllower class to save/restore nestable task state. BUG=None TEST=Existing unit tests R=jar@chromium.org, scottbyer@chromium.org, sky@chromium.org, akalin@chromium.org, rsleevi@chromium.org, brettw@chromium.org, tony@chromium.org Review URL: https://chromiumcodereview.appspot.com/9384024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121914 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi')
-rw-r--r--ppapi/proxy/ppb_testing_proxy.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/ppapi/proxy/ppb_testing_proxy.cc b/ppapi/proxy/ppb_testing_proxy.cc
index 9c0a14b..d1f5cec 100644
--- a/ppapi/proxy/ppb_testing_proxy.cc
+++ b/ppapi/proxy/ppb_testing_proxy.cc
@@ -50,10 +50,8 @@ PP_Bool ReadImageData(PP_Resource graphics_2d,
}
void RunMessageLoop(PP_Instance instance) {
- bool old_state = MessageLoop::current()->NestableTasksAllowed();
- MessageLoop::current()->SetNestableTasksAllowed(true);
+ MessageLoop::ScopedNestableTaskAllower allow(MessageLoop::current());
MessageLoop::current()->Run();
- MessageLoop::current()->SetNestableTasksAllowed(old_state);
}
void QuitMessageLoop(PP_Instance instance) {