accesskit_unix/atspi/interfaces/
mod.rs

1// Copyright 2022 The AccessKit Authors. All rights reserved.
2// Licensed under the Apache License, Version 2.0 (found in
3// the LICENSE-APACHE file) or the MIT license (found in
4// the LICENSE-MIT file), at your option.
5
6mod accessible;
7mod action;
8mod application;
9mod component;
10mod selection;
11mod text;
12mod value;
13
14use crate::atspi::{ObjectId, OwnedObjectAddress};
15use zbus::{fdo, names::UniqueName};
16
17fn map_root_error(error: accesskit_atspi_common::Error) -> fdo::Error {
18    crate::util::map_error(ObjectId::Root, error)
19}
20
21fn optional_object_address(
22    bus_name: &UniqueName,
23    object_id: Option<ObjectId>,
24) -> (OwnedObjectAddress,) {
25    match object_id {
26        Some(id) => (id.to_address(bus_name),),
27        None => (OwnedObjectAddress::null(),),
28    }
29}
30
31pub(crate) use accessible::*;
32pub(crate) use action::*;
33pub(crate) use application::*;
34pub(crate) use component::*;
35pub(crate) use selection::*;
36pub(crate) use text::*;
37pub(crate) use value::*;