use thiserror::Error;
use crate::types::DisplayId;
#[derive(Error, Debug)]
pub enum DisplayError {
#[error("Failed to connect to the graphics subsystem.")]
ConnectionFailed,
#[error("Interface or monitor '{0:?}' not found.")]
NotFound(DisplayId),
#[error("The system rejected the requested configuration.")]
ConfigurationRejected,
#[error("HDR Error: {0}")]
HdrError(String),
#[error("Feature not supported on this platform: {0}")]
UnsupportedFeature(String),
#[error("Platform-specific backend error: {0}")]
BackendError(String),
#[error("IO Error: {0}")]
Io(#[from] std::io::Error),
}
pub type DisplayResult<T> = Result<T, DisplayError>;