summaryrefslogtreecommitdiffstats
path: root/mojo/aura
diff options
context:
space:
mode:
Diffstat (limited to 'mojo/aura')
-rw-r--r--mojo/aura/window_tree_host_mojo.cc6
-rw-r--r--mojo/aura/window_tree_host_mojo.h6
2 files changed, 6 insertions, 6 deletions
diff --git a/mojo/aura/window_tree_host_mojo.cc b/mojo/aura/window_tree_host_mojo.cc
index b623bbd..9aba1d8 100644
--- a/mojo/aura/window_tree_host_mojo.cc
+++ b/mojo/aura/window_tree_host_mojo.cc
@@ -26,12 +26,14 @@ mojo::ContextFactoryMojo* WindowTreeHostMojo::context_factory_ = NULL;
// WindowTreeHostMojo, public:
WindowTreeHostMojo::WindowTreeHostMojo(
- ScopedNativeViewportHandle viewport_handle,
+ NativeViewportPtr viewport,
const gfx::Rect& bounds,
const base::Callback<void()>& compositor_created_callback)
- : native_viewport_(viewport_handle.Pass(), this),
+ : native_viewport_(viewport.Pass()),
compositor_created_callback_(compositor_created_callback),
bounds_(bounds) {
+ native_viewport_->SetClient(this);
+
AllocationScope scope;
native_viewport_->Create(bounds);
diff --git a/mojo/aura/window_tree_host_mojo.h b/mojo/aura/window_tree_host_mojo.h
index c53e884..1a02b77 100644
--- a/mojo/aura/window_tree_host_mojo.h
+++ b/mojo/aura/window_tree_host_mojo.h
@@ -6,8 +6,6 @@
#define MOJO_AURA_WINDOW_TREE_HOST_MOJO_H_
#include "base/bind.h"
-#include "mojo/public/cpp/bindings/error_handler.h"
-#include "mojo/public/cpp/bindings/remote_ptr.h"
#include "mojo/services/native_viewport/native_viewport.mojom.h"
#include "ui/aura/window_tree_host.h"
#include "ui/events/event_source.h"
@@ -25,7 +23,7 @@ class WindowTreeHostMojo : public aura::WindowTreeHost,
public ui::EventSource,
public NativeViewportClient {
public:
- WindowTreeHostMojo(ScopedNativeViewportHandle viewport_handle,
+ WindowTreeHostMojo(NativeViewportPtr viewport,
const gfx::Rect& bounds,
const base::Callback<void()>& compositor_created_callback);
virtual ~WindowTreeHostMojo();
@@ -61,7 +59,7 @@ class WindowTreeHostMojo : public aura::WindowTreeHost,
static ContextFactoryMojo* context_factory_;
- RemotePtr<NativeViewport> native_viewport_;
+ NativeViewportPtr native_viewport_;
base::Callback<void()> compositor_created_callback_;
gfx::Rect bounds_;