| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/wm/core/cursor_manager.h" | 5 #include "ui/wm/core/cursor_manager.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 IsMouseEventsEnabled() != state_on_unlock_->mouse_events_enabled()) { | 155 IsMouseEventsEnabled() != state_on_unlock_->mouse_events_enabled()) { |
| 156 delegate_->SetMouseEventsEnabled(state_on_unlock_->mouse_events_enabled(), | 156 delegate_->SetMouseEventsEnabled(state_on_unlock_->mouse_events_enabled(), |
| 157 this); | 157 this); |
| 158 } | 158 } |
| 159 } | 159 } |
| 160 | 160 |
| 161 bool CursorManager::IsMouseEventsEnabled() const { | 161 bool CursorManager::IsMouseEventsEnabled() const { |
| 162 return current_state_->mouse_events_enabled(); | 162 return current_state_->mouse_events_enabled(); |
| 163 } | 163 } |
| 164 | 164 |
| 165 void CursorManager::SetDisplay(const gfx::Display& display) { | 165 void CursorManager::SetDisplay(const display::Display& display) { |
| 166 delegate_->SetDisplay(display, this); | 166 delegate_->SetDisplay(display, this); |
| 167 } | 167 } |
| 168 | 168 |
| 169 void CursorManager::LockCursor() { | 169 void CursorManager::LockCursor() { |
| 170 cursor_lock_count_++; | 170 cursor_lock_count_++; |
| 171 } | 171 } |
| 172 | 172 |
| 173 void CursorManager::UnlockCursor() { | 173 void CursorManager::UnlockCursor() { |
| 174 cursor_lock_count_--; | 174 cursor_lock_count_--; |
| 175 DCHECK_GE(cursor_lock_count_, 0); | 175 DCHECK_GE(cursor_lock_count_, 0); |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 222 | 222 |
| 223 void CursorManager::CommitCursorSet(ui::CursorSetType cursor_set) { | 223 void CursorManager::CommitCursorSet(ui::CursorSetType cursor_set) { |
| 224 current_state_->set_cursor_set(cursor_set); | 224 current_state_->set_cursor_set(cursor_set); |
| 225 } | 225 } |
| 226 | 226 |
| 227 void CursorManager::CommitMouseEventsEnabled(bool enabled) { | 227 void CursorManager::CommitMouseEventsEnabled(bool enabled) { |
| 228 current_state_->SetMouseEventsEnabled(enabled); | 228 current_state_->SetMouseEventsEnabled(enabled); |
| 229 } | 229 } |
| 230 | 230 |
| 231 } // namespace wm | 231 } // namespace wm |
| OLD | NEW |