OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/platform_window/win/win_window.h" | 5 #include "ui/platform_window/win/win_window.h" |
6 | 6 |
7 #include "base/profiler/scoped_tracker.h" | 7 #include "base/profiler/scoped_tracker.h" |
8 #include "ui/events/event.h" | 8 #include "ui/events/event.h" |
9 #include "ui/events/event_utils.h" | 9 #include "ui/events/event_utils.h" |
10 #include "ui/gfx/win/msg_util.h" | 10 #include "ui/gfx/win/msg_util.h" |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 void WinWindow::Maximize() {} | 100 void WinWindow::Maximize() {} |
101 | 101 |
102 void WinWindow::Minimize() {} | 102 void WinWindow::Minimize() {} |
103 | 103 |
104 void WinWindow::Restore() {} | 104 void WinWindow::Restore() {} |
105 | 105 |
106 void WinWindow::SetCursor(PlatformCursor cursor) {} | 106 void WinWindow::SetCursor(PlatformCursor cursor) {} |
107 | 107 |
108 void WinWindow::MoveCursorTo(const gfx::Point& location) {} | 108 void WinWindow::MoveCursorTo(const gfx::Point& location) {} |
109 | 109 |
| 110 void WinWindow::ConfineCursorToBounds(const gfx::Rect& bounds) { |
| 111 } |
| 112 |
110 LRESULT WinWindow::OnMouseRange(UINT message, WPARAM w_param, LPARAM l_param) { | 113 LRESULT WinWindow::OnMouseRange(UINT message, WPARAM w_param, LPARAM l_param) { |
111 // TODO(vadimt): Remove ScopedTracker below once crbug.com/440919 is fixed. | 114 // TODO(vadimt): Remove ScopedTracker below once crbug.com/440919 is fixed. |
112 tracked_objects::ScopedTracker tracking_profile( | 115 tracked_objects::ScopedTracker tracking_profile( |
113 FROM_HERE_WITH_EXPLICIT_FUNCTION("440919 WinWindow::OnMouseRange")); | 116 FROM_HERE_WITH_EXPLICIT_FUNCTION("440919 WinWindow::OnMouseRange")); |
114 | 117 |
115 MSG msg = { hwnd(), message, w_param, l_param, GetMessageTime(), | 118 MSG msg = { hwnd(), message, w_param, l_param, GetMessageTime(), |
116 { CR_GET_X_LPARAM(l_param), CR_GET_Y_LPARAM(l_param) } }; | 119 { CR_GET_X_LPARAM(l_param), CR_GET_Y_LPARAM(l_param) } }; |
117 MouseEvent event(msg); | 120 MouseEvent event(msg); |
118 if (IsMouseEventFromTouch(message)) | 121 if (IsMouseEventFromTouch(message)) |
119 event.set_flags(event.flags() | EF_FROM_TOUCH); | 122 event.set_flags(event.flags() | EF_FROM_TOUCH); |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 | 213 |
211 namespace test { | 214 namespace test { |
212 | 215 |
213 // static | 216 // static |
214 void SetUsePopupAsRootWindowForTest(bool use) { | 217 void SetUsePopupAsRootWindowForTest(bool use) { |
215 use_popup_as_root_window_for_test = use; | 218 use_popup_as_root_window_for_test = use; |
216 } | 219 } |
217 | 220 |
218 } // namespace test | 221 } // namespace test |
219 } // namespace ui | 222 } // namespace ui |
OLD | NEW |