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

Unified Diff: mojo/system/core_impl.h

Issue 135073002: Mojo: Add the beginnings of a proper embedder API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 | « mojo/shell/context.cc ('k') | mojo/system/embedder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/system/core_impl.h
diff --git a/mojo/system/core_impl.h b/mojo/system/core_impl.h
index 2556759daeae13bd1249d6c09bc8ee1f04b8e0ef..446d7d471d85497f5eaca3f978260d6cf3bd5612 100644
--- a/mojo/system/core_impl.h
+++ b/mojo/system/core_impl.h
@@ -14,6 +14,11 @@
#include "mojo/system/system_impl_export.h"
namespace mojo {
+
+namespace embedder {
+void Init(); // So it can be friended.
+}
+
namespace system {
class CoreImpl;
@@ -23,10 +28,8 @@ namespace test {
class CoreTestBase;
}
-// |CoreImpl| is a singleton object that implements the Mojo system calls. With
-// the (obvious) exception of |Init()|, which must be called first (and the call
-// completed) before making any other calls, all the public methods are
-// thread-safe.
+// |CoreImpl| is a singleton object that implements the Mojo system calls. All
+// public methods are thread-safe.
class MOJO_SYSTEM_IMPL_EXPORT CoreImpl : public Core {
public:
static void Init();
@@ -82,6 +85,7 @@ class MOJO_SYSTEM_IMPL_EXPORT CoreImpl : public Core {
uint32_t num_bytes_read) OVERRIDE;
private:
+ friend void ::mojo::embedder::Init();
darin (slow to review) 2014/01/10 22:48:54 it doesn't work to just say "embedder::Init()" her
viettrungluu 2014/01/11 00:30:38 Done.
friend class test::CoreTestBase;
// The |busy| member is used only to deal with functions (in particular
@@ -152,6 +156,7 @@ class MOJO_SYSTEM_IMPL_EXPORT CoreImpl : public Core {
};
} // namespace system
+
} // namespace mojo
#endif // MOJO_SYSTEM_CORE_IMPL_H_
« no previous file with comments | « mojo/shell/context.cc ('k') | mojo/system/embedder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698