| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/aura/root_window_host_win.h" | 5 #include "ui/aura/root_window_host_win.h" |
| 6 | 6 |
| 7 #include <windows.h> | 7 #include <windows.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 | 10 |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 void RootWindowHostWin::SetCursor(gfx::NativeCursor native_cursor) { | 212 void RootWindowHostWin::SetCursor(gfx::NativeCursor native_cursor) { |
| 213 // Custom web cursors are handled directly. | 213 // Custom web cursors are handled directly. |
| 214 if (native_cursor == kCursorCustom) | 214 if (native_cursor == kCursorCustom) |
| 215 return; | 215 return; |
| 216 const wchar_t* cursor_id = GetCursorId(native_cursor); | 216 const wchar_t* cursor_id = GetCursorId(native_cursor); |
| 217 // TODO(jamescook): Support for non-system cursors will require finding | 217 // TODO(jamescook): Support for non-system cursors will require finding |
| 218 // the appropriate module to pass to LoadCursor(). | 218 // the appropriate module to pass to LoadCursor(). |
| 219 ::SetCursor(LoadCursor(NULL, cursor_id)); | 219 ::SetCursor(LoadCursor(NULL, cursor_id)); |
| 220 } | 220 } |
| 221 | 221 |
| 222 void RootWindowHostWin::SetCustomCursor(const gfx::PlatformCursor& cursor) { |
| 223 NOTIMPLEMENTED(); |
| 224 } |
| 225 |
| 222 void RootWindowHostWin::SetCapture() { | 226 void RootWindowHostWin::SetCapture() { |
| 223 if (!has_capture_) { | 227 if (!has_capture_) { |
| 224 has_capture_ = true; | 228 has_capture_ = true; |
| 225 ::SetCapture(hwnd()); | 229 ::SetCapture(hwnd()); |
| 226 } | 230 } |
| 227 } | 231 } |
| 228 | 232 |
| 229 void RootWindowHostWin::ReleaseCapture() { | 233 void RootWindowHostWin::ReleaseCapture() { |
| 230 if (has_capture_) { | 234 if (has_capture_) { |
| 231 has_capture_ = false; | 235 has_capture_ = false; |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 310 } | 314 } |
| 311 | 315 |
| 312 void RootWindowHostWin::OnSize(UINT param, const CSize& size) { | 316 void RootWindowHostWin::OnSize(UINT param, const CSize& size) { |
| 313 // Minimizing resizes the window to 0x0 which causes our layout to go all | 317 // Minimizing resizes the window to 0x0 which causes our layout to go all |
| 314 // screwy, so we just ignore it. | 318 // screwy, so we just ignore it. |
| 315 if (param != SIZE_MINIMIZED) | 319 if (param != SIZE_MINIMIZED) |
| 316 root_window_->OnHostResized(gfx::Size(size.cx, size.cy)); | 320 root_window_->OnHostResized(gfx::Size(size.cx, size.cy)); |
| 317 } | 321 } |
| 318 | 322 |
| 319 } // namespace aura | 323 } // namespace aura |
| OLD | NEW |