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 #include "ui/accessibility/platform/ax_platform_node_auralinux.h" | 5 #include "ui/accessibility/platform/ax_platform_node_auralinux.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/strings/sys_string_conversions.h" | 8 #include "base/strings/sys_string_conversions.h" |
| 9 #include "base/task_runner.h" |
9 #include "ui/accessibility/ax_node_data.h" | 10 #include "ui/accessibility/ax_node_data.h" |
10 #include "ui/accessibility/platform/atk_util_auralinux.h" | 11 #include "ui/accessibility/platform/atk_util_auralinux.h" |
11 #include "ui/accessibility/platform/ax_platform_node_delegate.h" | 12 #include "ui/accessibility/platform/ax_platform_node_delegate.h" |
12 | 13 |
13 // | 14 // |
14 // ax_platform_node_auralinux AtkObject definition and implementation. | 15 // ax_platform_node_auralinux AtkObject definition and implementation. |
15 // | 16 // |
16 | 17 |
17 G_BEGIN_DECLS | 18 G_BEGIN_DECLS |
18 | 19 |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
280 node->Init(delegate); | 281 node->Init(delegate); |
281 return node; | 282 return node; |
282 } | 283 } |
283 | 284 |
284 // static | 285 // static |
285 AXPlatformNode* AXPlatformNodeAuraLinux::application_ = nullptr; | 286 AXPlatformNode* AXPlatformNodeAuraLinux::application_ = nullptr; |
286 | 287 |
287 // static | 288 // static |
288 void AXPlatformNodeAuraLinux::SetApplication(AXPlatformNode* application) { | 289 void AXPlatformNodeAuraLinux::SetApplication(AXPlatformNode* application) { |
289 application_ = application; | 290 application_ = application; |
290 AtkUtilAuraLinux::GetInstance(); | 291 } |
| 292 |
| 293 // static |
| 294 void AXPlatformNodeAuraLinux::StaticInitialize( |
| 295 scoped_refptr<base::TaskRunner> init_task_runner) { |
| 296 AtkUtilAuraLinux::GetInstance()->Initialize(init_task_runner); |
291 } | 297 } |
292 | 298 |
293 AtkRole AXPlatformNodeAuraLinux::GetAtkRole() { | 299 AtkRole AXPlatformNodeAuraLinux::GetAtkRole() { |
294 switch (GetData().role) { | 300 switch (GetData().role) { |
295 case ui::AX_ROLE_ALERT: | 301 case ui::AX_ROLE_ALERT: |
296 return ATK_ROLE_ALERT; | 302 return ATK_ROLE_ALERT; |
297 case ui::AX_ROLE_APPLICATION: | 303 case ui::AX_ROLE_APPLICATION: |
298 return ATK_ROLE_APPLICATION; | 304 return ATK_ROLE_APPLICATION; |
299 case ui::AX_ROLE_BUTTON: | 305 case ui::AX_ROLE_BUTTON: |
300 return ATK_ROLE_PUSH_BUTTON; | 306 return ATK_ROLE_PUSH_BUTTON; |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
386 } | 392 } |
387 | 393 |
388 void AXPlatformNodeAuraLinux::NotifyAccessibilityEvent(ui::AXEvent event_type) { | 394 void AXPlatformNodeAuraLinux::NotifyAccessibilityEvent(ui::AXEvent event_type) { |
389 } | 395 } |
390 | 396 |
391 int AXPlatformNodeAuraLinux::GetIndexInParent() { | 397 int AXPlatformNodeAuraLinux::GetIndexInParent() { |
392 return 0; | 398 return 0; |
393 } | 399 } |
394 | 400 |
395 } // namespace ui | 401 } // namespace ui |
OLD | NEW |