Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(20)

Side by Side Diff: ui/events/devices/input_device_manager.cc

Issue 2028593004: Add new InputDeviceManager interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove_keyboard
Patch Set: Fix windows compile error. Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "ui/events/devices/input_device_manager.h"
6
7 namespace ui {
8
9 InputDeviceManager* InputDeviceManager::instance_ = nullptr;
10
11 // static
12 InputDeviceManager* InputDeviceManager::GetInstance() {
13 DCHECK(instance_);
14 return instance_;
15 }
16
17 // static
18 bool InputDeviceManager::HasInstance() {
19 return instance_ != nullptr;
20 }
21
22 // static
23 void InputDeviceManager::SetInstance(InputDeviceManager* instance) {
24 DCHECK(!instance_);
25 instance_ = instance;
26 }
27
28 // static
29 void InputDeviceManager::ClearInstance() {
30 instance_ = nullptr;
31 }
32
33 } // namespace ui
OLDNEW
« no previous file with comments | « ui/events/devices/input_device_manager.h ('k') | ui/events/devices/x11/device_data_manager_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698