Fix unused imports

This commit is contained in:
Victor Berger 2021-07-13 14:18:23 +02:00 committed by Victor Berger
parent cb92938587
commit e60374a459
2 changed files with 10 additions and 7 deletions

View File

@ -1,7 +1,9 @@
//! Type safe native types for safe context/surface creation
use super::{display::EGLDisplayHandle, ffi, wrap_egl_call, SwapBuffersError};
use nix::libc::{c_int, c_void};
#[cfg(feature = "backend_winit")]
use std::os::raw::c_int;
use std::os::raw::c_void;
#[cfg(feature = "backend_gbm")]
use std::os::unix::io::AsRawFd;
use std::{fmt::Debug, marker::PhantomData, sync::Arc};
@ -9,9 +11,7 @@ use std::{fmt::Debug, marker::PhantomData, sync::Arc};
#[cfg(feature = "backend_winit")]
use wayland_egl as wegl;
#[cfg(feature = "backend_winit")]
use winit::platform::unix::WindowExtUnix;
#[cfg(feature = "backend_winit")]
use winit::window::Window as WinitWindow;
use winit::{platform::unix::WindowExtUnix, window::Window as WinitWindow};
#[cfg(feature = "backend_gbm")]
use gbm::{AsRaw, Device as GbmDevice};

View File

@ -10,7 +10,7 @@
use std::collections::HashSet;
use std::error::Error;
use crate::utils::{Buffer, Physical, Point, Size};
use crate::utils::{Physical, Point, Size};
#[cfg(feature = "wayland_frontend")]
use crate::{utils::Rectangle, wayland::compositor::SurfaceData};
@ -20,8 +20,6 @@ use wayland_server::protocol::{wl_buffer, wl_shm};
#[cfg(feature = "renderer_gl")]
pub mod gles2;
#[cfg(feature = "wayland_frontend")]
use crate::backend::allocator::{dmabuf::Dmabuf, Format};
#[cfg(all(
feature = "wayland_frontend",
feature = "backend_egl",
@ -31,6 +29,11 @@ use crate::backend::egl::{
display::{EGLBufferReader, BUFFER_READER},
Error as EglError,
};
#[cfg(feature = "wayland_frontend")]
use crate::{
backend::allocator::{dmabuf::Dmabuf, Format},
utils::Buffer,
};
#[derive(Debug, PartialEq, Eq, Hash, Clone, Copy)]
/// Possible transformations to two-dimensional planes