| 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 "extensions/shell/browser/shell_desktop_controller_aura.h" | 5 #include "extensions/shell/browser/shell_desktop_controller_aura.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 | 127 |
| 128 if (visible) { | 128 if (visible) { |
| 129 SetCursor(delegate->GetCursor(), delegate); | 129 SetCursor(delegate->GetCursor(), delegate); |
| 130 } else { | 130 } else { |
| 131 gfx::NativeCursor invisible_cursor(ui::CursorType::kNone); | 131 gfx::NativeCursor invisible_cursor(ui::CursorType::kNone); |
| 132 image_cursors_->SetPlatformCursor(&invisible_cursor); | 132 image_cursors_->SetPlatformCursor(&invisible_cursor); |
| 133 ApplyCursor(invisible_cursor); | 133 ApplyCursor(invisible_cursor); |
| 134 } | 134 } |
| 135 } | 135 } |
| 136 | 136 |
| 137 void SetCursorSet(ui::CursorSetType cursor_set, | 137 void SetCursorSize(ui::CursorSize cursor_size, |
| 138 wm::NativeCursorManagerDelegate* delegate) override { | 138 wm::NativeCursorManagerDelegate* delegate) override { |
| 139 image_cursors_->SetCursorSet(cursor_set); | 139 image_cursors_->SetCursorSize(cursor_size); |
| 140 delegate->CommitCursorSet(cursor_set); | 140 delegate->CommitCursorSize(cursor_size); |
| 141 if (delegate->IsCursorVisible()) | 141 if (delegate->IsCursorVisible()) |
| 142 SetCursor(delegate->GetCursor(), delegate); | 142 SetCursor(delegate->GetCursor(), delegate); |
| 143 } | 143 } |
| 144 | 144 |
| 145 void SetMouseEventsEnabled( | 145 void SetMouseEventsEnabled( |
| 146 bool enabled, | 146 bool enabled, |
| 147 wm::NativeCursorManagerDelegate* delegate) override { | 147 wm::NativeCursorManagerDelegate* delegate) override { |
| 148 delegate->CommitMouseEventsEnabled(enabled); | 148 delegate->CommitMouseEventsEnabled(enabled); |
| 149 SetVisibility(delegate->IsCursorVisible(), delegate); | 149 SetVisibility(delegate->IsCursorVisible(), delegate); |
| 150 } | 150 } |
| (...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 373 if (displays.empty()) | 373 if (displays.empty()) |
| 374 return gfx::Size(); | 374 return gfx::Size(); |
| 375 const display::DisplayMode* mode = displays[0]->current_mode(); | 375 const display::DisplayMode* mode = displays[0]->current_mode(); |
| 376 return mode ? mode->size() : gfx::Size(); | 376 return mode ? mode->size() : gfx::Size(); |
| 377 #else | 377 #else |
| 378 return gfx::Size(); | 378 return gfx::Size(); |
| 379 #endif | 379 #endif |
| 380 } | 380 } |
| 381 | 381 |
| 382 } // namespace extensions | 382 } // namespace extensions |
| OLD | NEW |