use thiserror::Error;
pub type Result<T> = std::result::Result<T, Error>;
#[derive(Debug, Error)]
pub enum Error {
#[error("hook is already running")]
AlreadyRunning,
#[error("hook is not running")]
NotRunning,
#[error("failed to start hook: {0}")]
HookStartFailed(String),
#[error("failed to stop hook: {0}")]
HookStopFailed(String),
#[error("failed to simulate event: {0}")]
SimulateFailed(String),
#[error("platform error: {0}")]
Platform(String),
#[error("permission denied: {0}")]
PermissionDenied(String),
#[error("thread error: {0}")]
ThreadError(String),
#[error("not supported: {0}")]
NotSupported(String),
#[error("{0}")]
Other(String),
}