Index: ui/aura/remote_window_tree_host_win.cc |
diff --git a/ui/aura/remote_window_tree_host_win.cc b/ui/aura/remote_window_tree_host_win.cc |
index 19715ba4f3ff8e9aab10a125270a42b7a9d1405d..6525588cfee9dab063f276aba79b894ff4d98de5 100644 |
--- a/ui/aura/remote_window_tree_host_win.cc |
+++ b/ui/aura/remote_window_tree_host_win.cc |
@@ -149,16 +149,17 @@ void HandleMetroExit() { |
RemoteWindowTreeHostWin* g_instance = NULL; |
+// static |
RemoteWindowTreeHostWin* RemoteWindowTreeHostWin::Instance() { |
- if (g_instance) |
- return g_instance; |
- return Create(gfx::Rect()); |
+ if (!g_instance) |
+ g_instance = new RemoteWindowTreeHostWin(gfx::Rect()); |
+ return g_instance; |
} |
-RemoteWindowTreeHostWin* RemoteWindowTreeHostWin::Create( |
- const gfx::Rect& bounds) { |
- g_instance = g_instance ? g_instance : new RemoteWindowTreeHostWin(bounds); |
- return g_instance; |
+// static |
+void RemoteWindowTreeHostWin::SetInstance(RemoteWindowTreeHostWin* instance) { |
+ CHECK(!g_instance); |
+ g_instance = instance; |
} |
RemoteWindowTreeHostWin::RemoteWindowTreeHostWin(const gfx::Rect& bounds) |
@@ -390,9 +391,6 @@ void RemoteWindowTreeHostWin::Hide() { |
NOTIMPLEMENTED(); |
} |
-void RemoteWindowTreeHostWin::ToggleFullScreen() { |
-} |
- |
gfx::Rect RemoteWindowTreeHostWin::GetBounds() const { |
return gfx::Rect(window_size_); |
} |
@@ -402,13 +400,6 @@ void RemoteWindowTreeHostWin::SetBounds(const gfx::Rect& bounds) { |
OnHostResized(bounds.size()); |
} |
-gfx::Insets RemoteWindowTreeHostWin::GetInsets() const { |
- return gfx::Insets(); |
-} |
- |
-void RemoteWindowTreeHostWin::SetInsets(const gfx::Insets& insets) { |
-} |
- |
gfx::Point RemoteWindowTreeHostWin::GetLocationOnNativeScreen() const { |
return gfx::Point(0, 0); |
} |
@@ -433,13 +424,6 @@ bool RemoteWindowTreeHostWin::QueryMouseLocation(gfx::Point* location_return) { |
return true; |
} |
-bool RemoteWindowTreeHostWin::ConfineCursorToRootWindow() { |
- return true; |
-} |
- |
-void RemoteWindowTreeHostWin::UnConfineCursor() { |
-} |
- |
void RemoteWindowTreeHostWin::SetCursorNative(gfx::NativeCursor native_cursor) { |
if (!host_) |
return; |