Don't use the extended debug of the DisplayHandle in the error message

Keep the error message in one line.
Error such as

```
Error: Error creating OpenGL display (Ok(
    DisplayHandle(
        Wayland(
            WaylandDisplayHandle {
                display: 0x00005641c528e590,
            },
        ),
    ),
)) with glutin: not found
```

Are not easy to parse because of all the new lines
This commit is contained in:
Olivier Goffart 2025-06-25 11:43:53 +02:00
parent 3bb3a01d24
commit 526c5da24c
2 changed files with 2 additions and 2 deletions

View file

@ -92,7 +92,7 @@ impl OpenGLContext {
.build(active_event_loop, config_template_builder, config_picker)
.map_err(|glutin_err| {
format!(
"Error creating OpenGL display ({:#?}) with glutin: {}",
"Error creating OpenGL display ({:?}) with glutin: {}",
active_event_loop.display_handle(),
glutin_err
)

View file

@ -313,7 +313,7 @@ impl OpenGLSurface {
glutin::display::Display::new(_display_handle.as_raw(), display_api_preference)
.map_err(|glutin_error| {
format!(
"Error creating glutin display for native display {:#?}: {}",
"Error creating glutin display for native display {:?}: {}",
_display_handle.as_raw(),
glutin_error
)