#![deny(clippy::all, clippy::pedantic, clippy::cargo, unsafe_code)]
#![allow(clippy::module_name_repetitions)]
#[macro_use]
extern crate static_assertions;
#[macro_use]
pub(crate) mod macros;
pub mod accessible;
pub use accessible::Accessible;
pub mod interface;
pub use interface::{Interface, InterfaceSet};
pub mod state;
pub use state::{State, StateSet};
pub mod cache;
pub use cache::{CacheItem, LegacyCacheItem};
pub mod error;
pub use error::AtspiError;
pub mod events;
pub use events::{Event, GenericEvent};
mod role;
pub use role::Role;
mod relation_type;
pub use relation_type::RelationType;
use serde::{Deserialize, Serialize};
use zvariant::Type;
pub type MatchArgs<'a> = (
&'a [i32],
MatchType,
std::collections::HashMap<&'a str, &'a str>,
MatchType,
&'a [i32],
MatchType,
&'a [&'a str],
MatchType,
bool,
);
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize, Type)]
#[repr(u32)]
pub enum SortOrder {
Invalid,
Canonical,
Flow,
Tab,
ReverseCanonical,
ReverseFlow,
ReverseTab,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize, Type)]
#[repr(u32)]
pub enum TreeTraversalType {
RestrictChildren,
RestrictSibling,
Inorder,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize, Type)]
#[repr(i32)]
pub enum MatchType {
Invalid,
All,
Any,
NA,
Empty,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize, Type)]
#[repr(u32)]
pub enum CoordType {
Screen,
Window,
Parent,
}
#[derive(Clone, Copy, Debug, Hash, PartialEq, Eq, Serialize, Deserialize, Type)]
#[repr(u32)]
pub enum ClipType {
Neither,
Min,
Max,
Both,
}
#[derive(Clone, Copy, Debug, Hash, PartialEq, Eq, Serialize, Deserialize, Type)]
#[repr(u32)]
pub enum Granularity {
Char,
Word,
Sentence,
Line,
Paragraph,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize, Type)]
pub enum Layer {
Invalid,
Background,
Canvas,
Widget,
Mdi,
Popup,
Overlay,
Window,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize, Type)]
pub enum ScrollType {
TopLeft,
BottomRight,
TopEdge,
BottomEdge,
LeftEdge,
RightEdge,
Anywhere,
}
pub type MatcherArgs = (
Vec<Role>,
MatchType,
std::collections::HashMap<String, String>,
MatchType,
InterfaceSet,
MatchType,
);