Skip to content

Commit

Permalink
Convert CustomCursor back to Arc to avoid a breaking API change.
Browse files Browse the repository at this point in the history
  • Loading branch information
xStrom committed Feb 23, 2024
1 parent 4181af6 commit 2436d53
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions druid-shell/src/backend/windows/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,9 @@ struct DxgiState {
}

#[derive(Clone, PartialEq, Eq)]
pub struct CustomCursor(Rc<HCursor>);
// TODO: Convert this from Arc to Rc when doing a breaking release
#[allow(clippy::arc_with_non_send_sync)]
pub struct CustomCursor(Arc<HCursor>);

#[derive(PartialEq, Eq)]
struct HCursor(HCURSOR);
Expand Down Expand Up @@ -2435,7 +2437,9 @@ impl WindowHandle {
};
let icon = CreateIconIndirect(&mut icon_info);

Some(Cursor::Custom(CustomCursor(Rc::new(HCursor(icon)))))
// TODO: Convert this from Arc to Rc when doing a breaking release
#[allow(clippy::arc_with_non_send_sync)]
Some(Cursor::Custom(CustomCursor(Arc::new(HCursor(icon)))))
}
} else {
None
Expand Down

0 comments on commit 2436d53

Please sign in to comment.