summaryrefslogtreecommitdiffstats
path: root/mojo/examples/aura_demo
diff options
context:
space:
mode:
Diffstat (limited to 'mojo/examples/aura_demo')
-rw-r--r--mojo/examples/aura_demo/aura_demo.cc4
-rw-r--r--mojo/examples/aura_demo/demo_context_factory.cc2
-rw-r--r--mojo/examples/aura_demo/demo_context_factory.h6
-rw-r--r--mojo/examples/aura_demo/root_window_host_mojo.cc66
-rw-r--r--mojo/examples/aura_demo/root_window_host_mojo.h10
5 files changed, 44 insertions, 44 deletions
diff --git a/mojo/examples/aura_demo/aura_demo.cc b/mojo/examples/aura_demo/aura_demo.cc
index 2ac77cd..24f0a75 100644
--- a/mojo/examples/aura_demo/aura_demo.cc
+++ b/mojo/examples/aura_demo/aura_demo.cc
@@ -125,7 +125,7 @@ class AuraDemo : public ShellClient {
mojo::ScopedMessagePipeHandle client_handle, native_viewport_handle;
CreateMessagePipe(&client_handle, &native_viewport_handle);
- root_window_host_.reset(new RootWindowHostMojo(
+ root_window_host_.reset(new WindowTreeHostMojo(
native_viewport_handle.Pass(),
base::Bind(&AuraDemo::HostContextCreated, base::Unretained(this))));
mojo::AllocationScope scope;
@@ -183,7 +183,7 @@ class AuraDemo : public ShellClient {
aura::Window* window21_;
mojo::RemotePtr<Shell> shell_;
- scoped_ptr<RootWindowHostMojo> root_window_host_;
+ scoped_ptr<WindowTreeHostMojo> root_window_host_;
scoped_ptr<aura::RootWindow> root_window_;
};
diff --git a/mojo/examples/aura_demo/demo_context_factory.cc b/mojo/examples/aura_demo/demo_context_factory.cc
index 895d863..74956aa 100644
--- a/mojo/examples/aura_demo/demo_context_factory.cc
+++ b/mojo/examples/aura_demo/demo_context_factory.cc
@@ -61,7 +61,7 @@ class MojoContextProvider : public cc::ContextProvider {
} // namespace
-DemoContextFactory::DemoContextFactory(RootWindowHostMojo* rwhm) : rwhm_(rwhm) {
+DemoContextFactory::DemoContextFactory(WindowTreeHostMojo* rwhm) : rwhm_(rwhm) {
}
DemoContextFactory::~DemoContextFactory() {
diff --git a/mojo/examples/aura_demo/demo_context_factory.h b/mojo/examples/aura_demo/demo_context_factory.h
index f9fdac9..062db42 100644
--- a/mojo/examples/aura_demo/demo_context_factory.h
+++ b/mojo/examples/aura_demo/demo_context_factory.h
@@ -16,12 +16,12 @@ class ContextProviderInProcess;
namespace mojo {
namespace examples {
-class RootWindowHostMojo;
+class WindowTreeHostMojo;
// The default factory that creates in-process contexts.
class DemoContextFactory : public ui::ContextFactory {
public:
- explicit DemoContextFactory(RootWindowHostMojo* rwhm);
+ explicit DemoContextFactory(WindowTreeHostMojo* rwhm);
virtual ~DemoContextFactory();
// ContextFactory implementation
@@ -48,7 +48,7 @@ class DemoContextFactory : public ui::ContextFactory {
scoped_refptr<webkit::gpu::ContextProviderInProcess>
shared_main_thread_contexts_;
- RootWindowHostMojo* rwhm_;
+ WindowTreeHostMojo* rwhm_;
DISALLOW_COPY_AND_ASSIGN(DemoContextFactory);
};
diff --git a/mojo/examples/aura_demo/root_window_host_mojo.cc b/mojo/examples/aura_demo/root_window_host_mojo.cc
index 95d1ff0..98d96f7 100644
--- a/mojo/examples/aura_demo/root_window_host_mojo.cc
+++ b/mojo/examples/aura_demo/root_window_host_mojo.cc
@@ -18,12 +18,12 @@ namespace mojo {
namespace examples {
// static
-ui::ContextFactory* RootWindowHostMojo::context_factory_ = NULL;
+ui::ContextFactory* WindowTreeHostMojo::context_factory_ = NULL;
////////////////////////////////////////////////////////////////////////////////
-// RootWindowHostMojo, public:
+// WindowTreeHostMojo, public:
-RootWindowHostMojo::RootWindowHostMojo(
+WindowTreeHostMojo::WindowTreeHostMojo(
ScopedMessagePipeHandle viewport_handle,
const base::Callback<void()>& compositor_created_callback)
: native_viewport_(viewport_handle.Pass(), this),
@@ -45,117 +45,117 @@ RootWindowHostMojo::RootWindowHostMojo(
gles2_client_.reset(new GLES2ClientImpl(
gles2_handle.Pass(),
- base::Bind(&RootWindowHostMojo::DidCreateContext,
+ base::Bind(&WindowTreeHostMojo::DidCreateContext,
base::Unretained(this))));
native_viewport_->CreateGLES2Context(gles2_client_handle.Pass());
}
-RootWindowHostMojo::~RootWindowHostMojo() {}
+WindowTreeHostMojo::~WindowTreeHostMojo() {}
////////////////////////////////////////////////////////////////////////////////
-// RootWindowHostMojo, aura::RootWindowHost implementation:
+// WindowTreeHostMojo, aura::WindowTreeHost implementation:
-aura::RootWindow* RootWindowHostMojo::GetRootWindow() {
+aura::RootWindow* WindowTreeHostMojo::GetRootWindow() {
return delegate_->AsRootWindow();
}
-gfx::AcceleratedWidget RootWindowHostMojo::GetAcceleratedWidget() {
+gfx::AcceleratedWidget WindowTreeHostMojo::GetAcceleratedWidget() {
NOTIMPLEMENTED();
return gfx::kNullAcceleratedWidget;
}
-void RootWindowHostMojo::Show() {
+void WindowTreeHostMojo::Show() {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::Hide() {
+void WindowTreeHostMojo::Hide() {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::ToggleFullScreen() {
+void WindowTreeHostMojo::ToggleFullScreen() {
NOTIMPLEMENTED();
}
-gfx::Rect RootWindowHostMojo::GetBounds() const {
+gfx::Rect WindowTreeHostMojo::GetBounds() const {
NOTIMPLEMENTED();
return gfx::Rect(500, 500);
}
-void RootWindowHostMojo::SetBounds(const gfx::Rect& bounds) {
+void WindowTreeHostMojo::SetBounds(const gfx::Rect& bounds) {
NOTIMPLEMENTED();
}
-gfx::Insets RootWindowHostMojo::GetInsets() const {
+gfx::Insets WindowTreeHostMojo::GetInsets() const {
NOTIMPLEMENTED();
return gfx::Insets();
}
-void RootWindowHostMojo::SetInsets(const gfx::Insets& insets) {
+void WindowTreeHostMojo::SetInsets(const gfx::Insets& insets) {
NOTIMPLEMENTED();
}
-gfx::Point RootWindowHostMojo::GetLocationOnNativeScreen() const {
+gfx::Point WindowTreeHostMojo::GetLocationOnNativeScreen() const {
return gfx::Point(0, 0);
}
-void RootWindowHostMojo::SetCapture() {
+void WindowTreeHostMojo::SetCapture() {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::ReleaseCapture() {
+void WindowTreeHostMojo::ReleaseCapture() {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::SetCursor(gfx::NativeCursor cursor) {
+void WindowTreeHostMojo::SetCursor(gfx::NativeCursor cursor) {
NOTIMPLEMENTED();
}
-bool RootWindowHostMojo::QueryMouseLocation(gfx::Point* location_return) {
+bool WindowTreeHostMojo::QueryMouseLocation(gfx::Point* location_return) {
NOTIMPLEMENTED();
return false;
}
-bool RootWindowHostMojo::ConfineCursorToRootWindow() {
+bool WindowTreeHostMojo::ConfineCursorToRootWindow() {
NOTIMPLEMENTED();
return false;
}
-void RootWindowHostMojo::UnConfineCursor() {
+void WindowTreeHostMojo::UnConfineCursor() {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::OnCursorVisibilityChanged(bool show) {
+void WindowTreeHostMojo::OnCursorVisibilityChanged(bool show) {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::MoveCursorTo(const gfx::Point& location) {
+void WindowTreeHostMojo::MoveCursorTo(const gfx::Point& location) {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::PostNativeEvent(
+void WindowTreeHostMojo::PostNativeEvent(
const base::NativeEvent& native_event) {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::OnDeviceScaleFactorChanged(float device_scale_factor) {
+void WindowTreeHostMojo::OnDeviceScaleFactorChanged(float device_scale_factor) {
NOTIMPLEMENTED();
}
-void RootWindowHostMojo::PrepareForShutdown() {
+void WindowTreeHostMojo::PrepareForShutdown() {
NOTIMPLEMENTED();
}
////////////////////////////////////////////////////////////////////////////////
-// RootWindowHostMojo, NativeViewportClient implementation:
+// WindowTreeHostMojo, NativeViewportClient implementation:
-void RootWindowHostMojo::OnCreated() {
+void WindowTreeHostMojo::OnCreated() {
}
-void RootWindowHostMojo::OnDestroyed() {
+void WindowTreeHostMojo::OnDestroyed() {
base::MessageLoop::current()->Quit();
}
-void RootWindowHostMojo::OnEvent(const Event& event) {
+void WindowTreeHostMojo::OnEvent(const Event& event) {
if (!event.location().is_null())
native_viewport_->AckEvent(event);
@@ -163,9 +163,9 @@ void RootWindowHostMojo::OnEvent(const Event& event) {
};
////////////////////////////////////////////////////////////////////////////////
-// RootWindowHostMojo, private:
+// WindowTreeHostMojo, private:
-void RootWindowHostMojo::DidCreateContext(gfx::Size viewport_size) {
+void WindowTreeHostMojo::DidCreateContext(gfx::Size viewport_size) {
CreateCompositor(GetAcceleratedWidget());
compositor_created_callback_.Run();
NotifyHostResized(viewport_size);
diff --git a/mojo/examples/aura_demo/root_window_host_mojo.h b/mojo/examples/aura_demo/root_window_host_mojo.h
index 3391ce3..3e35988 100644
--- a/mojo/examples/aura_demo/root_window_host_mojo.h
+++ b/mojo/examples/aura_demo/root_window_host_mojo.h
@@ -19,17 +19,17 @@ namespace examples {
class GLES2ClientImpl;
-class RootWindowHostMojo : public aura::RootWindowHost,
+class WindowTreeHostMojo : public aura::WindowTreeHost,
public NativeViewportClient {
public:
- RootWindowHostMojo(ScopedMessagePipeHandle viewport_handle,
+ WindowTreeHostMojo(ScopedMessagePipeHandle viewport_handle,
const base::Callback<void()>& compositor_created_callback);
- virtual ~RootWindowHostMojo();
+ virtual ~WindowTreeHostMojo();
GLES2ClientImpl* gles2_client() { return gles2_client_.get(); }
private:
- // RootWindowHost:
+ // WindowTreeHost:
virtual aura::RootWindow* GetRootWindow() OVERRIDE;
virtual gfx::AcceleratedWidget GetAcceleratedWidget() OVERRIDE;
virtual void Show() OVERRIDE;
@@ -65,7 +65,7 @@ class RootWindowHostMojo : public aura::RootWindowHost,
RemotePtr<NativeViewport> native_viewport_;
base::Callback<void()> compositor_created_callback_;
- DISALLOW_COPY_AND_ASSIGN(RootWindowHostMojo);
+ DISALLOW_COPY_AND_ASSIGN(WindowTreeHostMojo);
};
} // namespace examples