Skip to content

Commit

Permalink
use display as_mut()
Browse files Browse the repository at this point in the history
  • Loading branch information
raphamorim committed Jan 19, 2024
1 parent 93424ab commit 9360263
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions rio-backend/src/clipboard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
// which is licensed under Apache 2.0 license.

use log::warn;

use raw_window_handle::RawDisplayHandle;

#[derive(Debug, Clone, Copy, PartialEq, Eq)]
Expand Down Expand Up @@ -31,9 +30,11 @@ impl Clipboard {
pub unsafe fn new(display: RawDisplayHandle) -> Self {
match display {
#[cfg(all(feature = "wayland", not(any(target_os = "macos", windows))))]
RawDisplayHandle::Wayland(display) => {
RawDisplayHandle::Wayland(mut display) => {
let (selection, clipboard) =
wayland_clipboard::create_clipboards_from_external(display.display);
wayland_clipboard::create_clipboards_from_external(
*display.display.as_mut(),
);
Self {
clipboard: Box::new(clipboard),
selection: Some(Box::new(selection)),
Expand Down

0 comments on commit 9360263

Please sign in to comment.