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

Unified Diff: mojo/public/cpp/environment/lib/default_async_waiter.cc

Issue 339403003: Mojo: Make GetDefault{AsyncWaiter,Logger} static methods of Environment. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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
Index: mojo/public/cpp/environment/lib/default_async_waiter.cc
diff --git a/mojo/public/cpp/environment/lib/default_async_waiter.cc b/mojo/public/cpp/environment/lib/default_async_waiter.cc
index ae89a86f45e2d351eec422d29deec477643e8bf9..257f1c8d797c02c37e0341c158c0576fa11c7e28 100644
--- a/mojo/public/cpp/environment/lib/default_async_waiter.cc
+++ b/mojo/public/cpp/environment/lib/default_async_waiter.cc
@@ -2,14 +2,16 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "mojo/public/cpp/environment/default_async_waiter.h"
+#include "mojo/public/cpp/environment/lib/default_async_waiter.h"
#include <assert.h>
+#include "mojo/public/c/environment/async_waiter.h"
#include "mojo/public/cpp/utility/run_loop.h"
#include "mojo/public/cpp/utility/run_loop_handler.h"
namespace mojo {
+
namespace {
// RunLoopHandler implementation used for a request to AsyncWait(). There are
@@ -78,15 +80,15 @@ void CancelWait(MojoAsyncWaitID wait_id) {
delete reinterpret_cast<RunLoopHandlerImpl*>(wait_id);
}
+} // namespace
+
+namespace internal {
+
const MojoAsyncWaiter kDefaultAsyncWaiter = {
AsyncWait,
CancelWait
};
-} // namespace
-
-const MojoAsyncWaiter* GetDefaultAsyncWaiter() {
- return &kDefaultAsyncWaiter;
-}
+} // namespace internal
} // namespace mojo
« no previous file with comments | « mojo/public/cpp/environment/lib/default_async_waiter.h ('k') | mojo/public/cpp/environment/lib/default_logger.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698