OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #ifndef UI_ACCESSIBILITY_AX_UTIL_AURALINUX_H_ | 5 #ifndef UI_ACCESSIBILITY_AX_UTIL_AURALINUX_H_ |
6 #define UI_ACCESSIBILITY_AX_UTIL_AURALINUX_H_ | 6 #define UI_ACCESSIBILITY_AX_UTIL_AURALINUX_H_ |
7 | 7 |
8 #include "base/callback.h" | |
9 #include "base/memory/scoped_ptr.h" | |
8 #include "base/memory/singleton.h" | 10 #include "base/memory/singleton.h" |
9 #include "ui/accessibility/ax_export.h" | 11 #include "ui/accessibility/ax_export.h" |
10 | 12 |
13 namespace base { | |
14 class Thread; | |
15 } | |
16 | |
11 namespace ui { | 17 namespace ui { |
12 | 18 |
13 // This singleton class initializes ATK (accessibility toolkit) and | 19 // This singleton class initializes ATK (accessibility toolkit) and |
14 // registers an implementation of the AtkUtil class, a global class that | 20 // registers an implementation of the AtkUtil class, a global class that |
15 // every accessible application needs to register once. | 21 // every accessible application needs to register once. |
16 class AtkUtilAuraLinux { | 22 class AtkUtilAuraLinux { |
17 public: | 23 public: |
18 // Get the single instance of this class. | 24 // Get the single instance of this class. |
19 static AtkUtilAuraLinux* GetInstance(); | 25 static AtkUtilAuraLinux* GetInstance(); |
20 | 26 |
21 AtkUtilAuraLinux(); | 27 AtkUtilAuraLinux(); |
22 virtual ~AtkUtilAuraLinux(); | 28 virtual ~AtkUtilAuraLinux(); |
23 | |
24 private: | 29 private: |
25 friend struct DefaultSingletonTraits<AtkUtilAuraLinux>; | 30 friend struct DefaultSingletonTraits<AtkUtilAuraLinux>; |
31 | |
32 void CheckIfAccessibilityIsEnabled(); | |
33 void CheckPlatformAccessibilitySupport(); | |
34 void OnStopAccessibilityThread(); | |
35 | |
36 #if defined(USE_GCONF) || defined(USE_DBUS) | |
37 bool isEnabled; | |
dmazzoni
2015/04/20 16:33:22
is_enabled_
| |
38 scoped_ptr<base::Thread> accessibility_init_thread_; | |
39 #endif | |
26 }; | 40 }; |
27 | 41 |
28 } // namespace ui | 42 } // namespace ui |
29 | 43 |
30 #endif // UI_ACCESSIBILITY_AX_UTIL_AURALINUX_H_ | 44 #endif // UI_ACCESSIBILITY_AX_UTIL_AURALINUX_H_ |
OLD | NEW |