From 98c12c118cb593f7cc15ae095a836409e8d3701a Mon Sep 17 00:00:00 2001 From: Jaeheon Yi <jaeheon@google.com> Date: Mon, 13 May 2019 07:05:45 +0000 Subject: [PATCH] [scenic][accessibility] Delete obsolete a11y_input system. Design has changed, and this is no longer useful code. SCN-1124 #comment TEST=CQ Change-Id: Ia19f4cdeb3a3f263bd022bd3efdf8a5a8b675d6b --- garnet/bin/ui/scenic/BUILD.gn | 5 +--- garnet/bin/ui/scenic/app.cc | 4 --- garnet/lib/ui/a11y_input/BUILD.gn | 15 ---------- garnet/lib/ui/a11y_input/a11y_input_system.cc | 21 -------------- garnet/lib/ui/a11y_input/a11y_input_system.h | 28 ------------------- garnet/lib/ui/scenic/system.h | 2 -- 6 files changed, 1 insertion(+), 74 deletions(-) delete mode 100644 garnet/lib/ui/a11y_input/BUILD.gn delete mode 100644 garnet/lib/ui/a11y_input/a11y_input_system.cc delete mode 100644 garnet/lib/ui/a11y_input/a11y_input_system.h diff --git a/garnet/bin/ui/scenic/BUILD.gn b/garnet/bin/ui/scenic/BUILD.gn index 737d40df70c..6739565e4f6 100644 --- a/garnet/bin/ui/scenic/BUILD.gn +++ b/garnet/bin/ui/scenic/BUILD.gn @@ -39,10 +39,7 @@ executable("scenic") { if (enable_input_subsystem) { defines += [ "SCENIC_ENABLE_INPUT_SUBSYSTEM" ] - deps += [ - "//garnet/lib/ui/a11y_input", - "//garnet/lib/ui/input", - ] + deps += ["//garnet/lib/ui/input"] } # Extra stack needed to avoid crashes when loading vulkan validation layers diff --git a/garnet/bin/ui/scenic/app.cc b/garnet/bin/ui/scenic/app.cc index 0f8a35d4ca3..8015004809e 100644 --- a/garnet/bin/ui/scenic/app.cc +++ b/garnet/bin/ui/scenic/app.cc @@ -17,7 +17,6 @@ #endif #ifdef SCENIC_ENABLE_INPUT_SUBSYSTEM -#include "garnet/lib/ui/a11y_input/a11y_input_system.h" #include "garnet/lib/ui/input/input_system.h" #endif @@ -46,9 +45,6 @@ App::App(sys::ComponentContext* app_context, inspect::Node inspect_node, #ifdef SCENIC_ENABLE_GFX_SUBSYSTEM auto input = scenic_->RegisterSystem<input::InputSystem>(gfx); FXL_DCHECK(input); - - auto a11y_input = scenic_->RegisterSystem<a11y_input::A11yInputSystem>(gfx); - FXL_DCHECK(a11y_input); #else #error InputSystem requires gfx::GfxSystem. #endif diff --git a/garnet/lib/ui/a11y_input/BUILD.gn b/garnet/lib/ui/a11y_input/BUILD.gn deleted file mode 100644 index eac55fd05bf..00000000000 --- a/garnet/lib/ui/a11y_input/BUILD.gn +++ /dev/null @@ -1,15 +0,0 @@ -# Copyright 2019 The Fuchsia Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -source_set("a11y_input") { - sources = [ - "a11y_input_system.cc", - "a11y_input_system.h", - ] - - deps = [ - "//garnet/lib/ui/scenic", - "//garnet/public/lib/inspect", - ] -} diff --git a/garnet/lib/ui/a11y_input/a11y_input_system.cc b/garnet/lib/ui/a11y_input/a11y_input_system.cc deleted file mode 100644 index bfba0534fbb..00000000000 --- a/garnet/lib/ui/a11y_input/a11y_input_system.cc +++ /dev/null @@ -1,21 +0,0 @@ -#include "a11y_input_system.h" - -namespace scenic_impl { -namespace a11y_input { - -const char* A11yInputSystem::kName = "A11yInputSystem"; - -A11yInputSystem::A11yInputSystem(SystemContext context, - bool initialized_after_construction) - : System(std::move(context), initialized_after_construction) { - FXL_LOG(INFO) << "Scenic accessibility input system started."; -} - -CommandDispatcherUniquePtr A11yInputSystem::CreateCommandDispatcher( - CommandDispatcherContext context) { - return CommandDispatcherUniquePtr(/* command dispatcher */ nullptr, - /* custom deleter */ nullptr); -} - -} // namespace a11y_input -} // namespace scenic_impl diff --git a/garnet/lib/ui/a11y_input/a11y_input_system.h b/garnet/lib/ui/a11y_input/a11y_input_system.h deleted file mode 100644 index a7acce4ca8f..00000000000 --- a/garnet/lib/ui/a11y_input/a11y_input_system.h +++ /dev/null @@ -1,28 +0,0 @@ -#ifndef GARNET_LIB_UI_A11Y_INPUT_A11Y_INPUT_SYSTEM_H_ -#define GARNET_LIB_UI_A11Y_INPUT_A11Y_INPUT_SYSTEM_H_ - -#include <memory> - -#include "garnet/lib/ui/scenic/system.h" - -namespace scenic_impl { -namespace a11y_input { - -class A11yInputSystem : public System { - public: - static constexpr TypeId kTypeId = kA11yInput; - static const char* kName; - - explicit A11yInputSystem(SystemContext context, - bool initialized_after_construction); - ~A11yInputSystem() override = default; - - virtual CommandDispatcherUniquePtr CreateCommandDispatcher( - CommandDispatcherContext context) override; - - private: -}; -} // namespace a11y_input -} // namespace scenic_impl - -#endif // GARNET_LIB_UI_A11Y_INPUT_A11Y_INPUT_SYSTEM_H_ diff --git a/garnet/lib/ui/scenic/system.h b/garnet/lib/ui/scenic/system.h index 93d0a42a269..c6006c6505b 100644 --- a/garnet/lib/ui/scenic/system.h +++ b/garnet/lib/ui/scenic/system.h @@ -122,8 +122,6 @@ inline System::TypeId SystemTypeForCmd( case fuchsia::ui::scenic::Command::Tag::kGfx: return System::TypeId::kGfx; case fuchsia::ui::scenic::Command::Tag::kInput: - // TODO(SCN-1124): Provide a way to route input to a11y_input here when - // applicable. return System::TypeId::kInput; case fuchsia::ui::scenic::Command::Tag::kVectorial: return System::TypeId::kVectorial; -- GitLab