removed unnecessary clones

This commit is contained in:
buffet 2019-02-03 00:09:40 +01:00
parent 6d75714e38
commit 43f561e65a
2 changed files with 2 additions and 3 deletions

View file

@ -49,7 +49,7 @@ impl pointer::Handler for Pointer {
let shell_handle = &state.shells[0]; let shell_handle = &state.shells[0];
let seat_handle = state.seat_handle.clone().unwrap(); let seat_handle = state.seat_handle.clone().unwrap();
let keyboard_handle = state.keyboards[0].clone(); let keyboard_handle = &state.keyboards[0];
use shell_handle as shell; use shell_handle as shell;
match shell.state() { match shell.state() {

View file

@ -28,9 +28,8 @@ impl output::Handler for Output {
#[wlroots_dehandle(shell, surface, layout)] #[wlroots_dehandle(shell, surface, layout)]
fn render_shells(state: &mut CompositorState, renderer: &mut Renderer) { fn render_shells(state: &mut CompositorState, renderer: &mut Renderer) {
let shells = state.shells.clone();
let layout_handle = &state.layout_handle; let layout_handle = &state.layout_handle;
for shell_handle in shells { for shell_handle in &state.shells {
use shell_handle as shell; use shell_handle as shell;
let surface_handle = shell.surface(); let surface_handle = shell.surface();
use layout_handle as layout; use layout_handle as layout;