Change create_custom_cursor() to return Result (#3844)

This commit is contained in:
daxpedda
2024-08-06 18:57:03 +02:00
committed by GitHub
parent 29e1041987
commit f5304815a1
17 changed files with 141 additions and 87 deletions

View File

@@ -834,7 +834,10 @@ impl ActiveEventLoop {
}
}
pub fn create_custom_cursor(&self, cursor: CustomCursorSource) -> CustomCursor {
pub fn create_custom_cursor(
&self,
cursor: CustomCursorSource,
) -> Result<CustomCursor, ExternalError> {
x11_or_wayland!(match self; ActiveEventLoop(evlp) => evlp.create_custom_cursor(cursor))
}