diff options
author | sammc <sammc@chromium.org> | 2015-05-19 21:55:37 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-05-20 04:55:43 +0000 |
commit | ceff908a1afba3e54c7d6ec133654e5afb4007a6 (patch) | |
tree | 6d76e7ea5185a7838f868e39b2de57a89268b573 /extensions/renderer/mojo | |
parent | a6faceeb923420b8f8ec83029ecda0fffac5438f (diff) | |
download | chromium_src-ceff908a1afba3e54c7d6ec133654e5afb4007a6.zip chromium_src-ceff908a1afba3e54c7d6ec133654e5afb4007a6.tar.gz chromium_src-ceff908a1afba3e54c7d6ec133654e5afb4007a6.tar.bz2 |
Remove mojo::InterfaceImpl from extensions.
BUG=489751
Review URL: https://codereview.chromium.org/1148703002
Cr-Commit-Position: refs/heads/master@{#330699}
Diffstat (limited to 'extensions/renderer/mojo')
-rw-r--r-- | extensions/renderer/mojo/keep_alive_client_unittest.cc | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/extensions/renderer/mojo/keep_alive_client_unittest.cc b/extensions/renderer/mojo/keep_alive_client_unittest.cc index 4f23621..ae170b6 100644 --- a/extensions/renderer/mojo/keep_alive_client_unittest.cc +++ b/extensions/renderer/mojo/keep_alive_client_unittest.cc @@ -5,7 +5,7 @@ #include "extensions/common/mojo/keep_alive.mojom.h" #include "extensions/renderer/api_test_base.h" #include "grit/extensions_renderer_resources.h" -#include "third_party/mojo/src/mojo/public/cpp/bindings/interface_impl.h" +#include "third_party/mojo/src/mojo/public/cpp/bindings/strong_binding.h" // A test launcher for tests for the stash client defined in // extensions/test/data/keep_alive_client_unittest.js. @@ -15,22 +15,24 @@ namespace { // A KeepAlive implementation that calls provided callbacks on creation and // destruction. -class TestKeepAlive : public mojo::InterfaceImpl<KeepAlive> { +class TestKeepAlive : public KeepAlive { public: - explicit TestKeepAlive(const base::Closure& on_destruction) - : on_destruction_(on_destruction) {} + TestKeepAlive(const base::Closure& on_destruction, + mojo::InterfaceRequest<KeepAlive> keep_alive) + : on_destruction_(on_destruction), binding_(this, keep_alive.Pass()) {} ~TestKeepAlive() override { on_destruction_.Run(); } static void Create(const base::Closure& on_creation, const base::Closure& on_destruction, mojo::InterfaceRequest<KeepAlive> keep_alive) { - mojo::BindToRequest(new TestKeepAlive(on_destruction), &keep_alive); + new TestKeepAlive(on_destruction, keep_alive.Pass()); on_creation.Run(); } private: const base::Closure on_destruction_; + mojo::StrongBinding<KeepAlive> binding_; }; } // namespace |