OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "ash/mus/keyboard_ui_mus.h" | 5 #include "ash/mus/keyboard_ui_mus.h" |
6 | 6 |
7 #include "ash/common/keyboard/keyboard_ui_observer.h" | 7 #include "ash/keyboard/keyboard_ui_observer.h" |
8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
9 #include "services/service_manager/public/cpp/connector.h" | 9 #include "services/service_manager/public/cpp/connector.h" |
10 | 10 |
11 namespace ash { | 11 namespace ash { |
12 | 12 |
13 KeyboardUIMus::KeyboardUIMus(service_manager::Connector* connector) | 13 KeyboardUIMus::KeyboardUIMus(service_manager::Connector* connector) |
14 : is_enabled_(false), observer_binding_(this) { | 14 : is_enabled_(false), observer_binding_(this) { |
15 // TODO: chrome should register the keyboard interface with ash. | 15 // TODO: chrome should register the keyboard interface with ash. |
16 // http://crbug.com/683289. | 16 // http://crbug.com/683289. |
17 } | 17 } |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 const gfx::Rect& bounds) { | 51 const gfx::Rect& bounds) { |
52 if (is_enabled_ == is_enabled) | 52 if (is_enabled_ == is_enabled) |
53 return; | 53 return; |
54 | 54 |
55 is_enabled_ = is_enabled; | 55 is_enabled_ = is_enabled; |
56 for (auto& observer : *observers()) | 56 for (auto& observer : *observers()) |
57 observer.OnKeyboardEnabledStateChanged(is_enabled); | 57 observer.OnKeyboardEnabledStateChanged(is_enabled); |
58 } | 58 } |
59 | 59 |
60 } // namespace ash | 60 } // namespace ash |
OLD | NEW |