ax_event_mojom_traits.cc 664 B

123456789101112131415161718192021
  1. // Copyright 2018 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. #include "ui/accessibility/mojom/ax_event_mojom_traits.h"
  5. namespace mojo {
  6. // static
  7. bool StructTraits<ax::mojom::AXEventDataView, ui::AXEvent>::Read(
  8. ax::mojom::AXEventDataView data,
  9. ui::AXEvent* out) {
  10. out->event_type = data.event_type();
  11. out->id = data.id();
  12. out->event_from = data.event_from();
  13. out->event_from_action = data.event_from_action();
  14. out->action_request_id = data.action_request_id();
  15. return data.ReadEventIntents(&out->event_intents);
  16. }
  17. } // namespace mojo