propagate event tap creation error (#218)

This commit is contained in:
Ferdinand Schober
2024-10-25 16:31:15 +02:00
committed by GitHub
parent 9f52a2ac93
commit 75b790ec2e
2 changed files with 48 additions and 18 deletions

View File

@@ -93,7 +93,7 @@ pub enum CaptureCreationError {
#[error("error creating windows capture backend")]
Windows,
#[cfg(target_os = "macos")]
#[error("error creating macos capture backend")]
#[error("error creating macos capture backend: `{0}`")]
MacOS(#[from] MacosCaptureCreationError),
}
@@ -165,6 +165,9 @@ pub enum X11InputCaptureCreationError {
pub enum MacosCaptureCreationError {
#[error("event source creation failed!")]
EventSourceCreation,
#[cfg(target_os = "macos")]
#[error("event tap creation failed")]
EventTapCreation,
#[error("failed to set CG Cursor property")]
CGCursorProperty,
#[cfg(target_os = "macos")]