cargo fmt

This commit is contained in:
Drakulix 2017-09-20 20:06:58 +02:00
parent 518f7dbdfc
commit f09bdd0a30
6 changed files with 5 additions and 11 deletions

View File

@ -1,7 +1,6 @@
extern crate gl_generator;
use gl_generator::{Api, Fallbacks, Profile, Registry};
use std::env;
use std::fs::File;
use std::path::PathBuf;

View File

@ -1,7 +1,6 @@
//! Common traits for input backends to receive input from.
use backend::{SeatInternal, TouchSlotInternal};
use std::error::Error;
/// A seat describes a group of input devices and at least one

View File

@ -6,7 +6,6 @@ use input as libinput;
use input::event;
use std::collections::hash_map::{DefaultHasher, Entry, HashMap};
use std::hash::{Hash, Hasher};
use std::io::Error as IoError;
use std::rc::Rc;

View File

@ -11,8 +11,9 @@ pub struct RegionData {
impl RegionData {
/// Initialize the user_data of a region, must be called right when the surface is created
pub unsafe fn init(region: &wl_region::WlRegion) {
region.set_user_data(Box::into_raw(Box::new(Mutex::new(RegionData::default())))
as *mut _)
region.set_user_data(
Box::into_raw(Box::new(Mutex::new(RegionData::default()))) as *mut _,
)
}
/// Cleans the user_data of that surface, must be called when it is destroyed

View File

@ -21,14 +21,10 @@ use backend::input::KeyState;
use std::io::{Error as IoError, Write};
use std::os::unix::io::AsRawFd;
use std::sync::{Arc, Mutex};
use tempfile::tempfile;
use wayland_server::{Liveness, Resource};
use wayland_server::protocol::{wl_keyboard, wl_surface};
use xkbcommon::xkb;
pub use xkbcommon::xkb::{keysyms, Keysym};
/// Represents the current state of the keyboard modifiers

View File

@ -682,8 +682,8 @@ where
destroy: |evlh, idata, _, popup| {
let ptr = popup.get_user_data();
let &(ref surface, _, _) = unsafe {
&*(ptr
as *mut (
&*(ptr as
*mut (
wl_surface::WlSurface,
zxdg_shell_v6::ZxdgShellV6,
zxdg_surface_v6::ZxdgSurfaceV6,